diff options
| author | gingerBill <bill@gingerbill.org> | 2021-03-27 15:22:05 +0000 |
|---|---|---|
| committer | gingerBill <bill@gingerbill.org> | 2021-03-27 15:22:05 +0000 |
| commit | 1e587d6635e93ca36ad2e6c8615dffed2b92e1fb (patch) | |
| tree | b2e5126aaa891b08db2f1591f5e931f026fc611d /src/check_type.cpp | |
| parent | e21d7167200c76ff250db3308f1804b3314267c9 (diff) | |
Fix #883 - polymorphic specialization with target types of enumerated arrays
Diffstat (limited to 'src/check_type.cpp')
| -rw-r--r-- | src/check_type.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/check_type.cpp b/src/check_type.cpp index 3eada163c..881bb9600 100644 --- a/src/check_type.cpp +++ b/src/check_type.cpp @@ -1187,7 +1187,11 @@ bool check_type_specialization_to(CheckerContext *ctx, Type *specialization, Typ Type *t = base_type(type); Type *s = base_type(specialization); if (t->kind != s->kind) { - return false; + if (t->kind == Type_EnumeratedArray && s->kind == Type_Array) { + // Might be okay, check later + } else { + return false; + } } if (is_type_untyped(t)) { |