diff options
| author | Roman Smrž <roman.smrz@seznam.cz> | 2026-04-19 14:18:44 +0200 |
|---|---|---|
| committer | Roman Smrž <roman.smrz@seznam.cz> | 2026-04-19 14:35:19 +0200 |
| commit | bd2ae1a2eb918735c0a12000fb6239a78b7eb48b (patch) | |
| tree | cc1c8d340e9b18ecc0041dd3abc351a3243cdffa /src/Parser | |
| parent | 9a8b6b9202f2eb7a8f51ed04ceaf29d2a358f682 (diff) | |
Non-primitive result type in ExprTypeFunction constructor
Diffstat (limited to 'src/Parser')
| -rw-r--r-- | src/Parser/Core.hs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Parser/Core.hs b/src/Parser/Core.hs index c317067..f2445a2 100644 --- a/src/Parser/Core.hs +++ b/src/Parser/Core.hs @@ -106,7 +106,7 @@ lookupVarExpr off sline name = do case etype of ExprTypePrim (Proxy :: Proxy a) -> return $ SomeExpr $ (Variable sline fqn :: Expr a) ExprTypeConstr1 _ -> return $ SomeExpr $ (Undefined "incomplete type" :: Expr DynamicType) - ExprTypeFunction args (_ :: Proxy a) -> return $ SomeExpr $ (FunVariable args sline fqn :: Expr (FunctionType a)) + ExprTypeFunction args (ExprTypePrim (_ :: Proxy a)) -> return $ SomeExpr $ (FunVariable args sline fqn :: Expr (FunctionType a)) stype -> return $ SomeExpr $ DynVariable stype sline fqn lookupScalarVarExpr :: Int -> SourceLine -> VarName -> TestParser SomeExpr @@ -115,7 +115,7 @@ lookupScalarVarExpr off sline name = do case etype of ExprTypePrim (Proxy :: Proxy a) -> return $ SomeExpr $ (Variable sline fqn :: Expr a) ExprTypeConstr1 _ -> return $ SomeExpr $ (Undefined "incomplete type" :: Expr DynamicType) - ExprTypeFunction args (pa :: Proxy a) -> do + ExprTypeFunction args (ExprTypePrim (pa :: Proxy a)) -> do SomeExpr <$> unifyExpr off pa (FunVariable args sline fqn :: Expr (FunctionType a)) stype -> return $ SomeExpr $ DynVariable stype sline fqn |