diff options
Diffstat (limited to 'src/main/java')
| -rw-r--r-- | src/main/java/org/shedlang/compiler/typechecker/TypeChecker.java | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/main/java/org/shedlang/compiler/typechecker/TypeChecker.java b/src/main/java/org/shedlang/compiler/typechecker/TypeChecker.java index 3695a255..871c6dae 100644 --- a/src/main/java/org/shedlang/compiler/typechecker/TypeChecker.java +++ b/src/main/java/org/shedlang/compiler/typechecker/TypeChecker.java @@ -2053,6 +2053,9 @@ public class TypeChecker { context = typedExpressionResult.context(); var expressionTypeInfo = switch (typedExpression.type()) { + case ConstructedType<?> constructedType when constructedType.genericType() instanceof SumType -> + context.sumTypeInfo((ConstructedType<SumType>) constructedType, untyped.source()); + case SumType expressionType -> context.sumTypeInfo(expressionType, untyped.source()); |
