aboutsummaryrefslogtreecommitdiff
path: root/Sil/Compile.dcl
diff options
context:
space:
mode:
authorCamil Staps2017-07-20 20:25:25 +0000
committerCamil Staps2017-07-20 20:25:25 +0000
commitbc950badd0655328af7a9886988722809e367d07 (patch)
tree6411d00c5022b591697c206cc1261dafb8ec8b33 /Sil/Compile.dcl
parentAdd checks for locals with type Void (diff)
Type checking
Diffstat (limited to 'Sil/Compile.dcl')
-rw-r--r--Sil/Compile.dcl6
1 files changed, 5 insertions, 1 deletions
diff --git a/Sil/Compile.dcl b/Sil/Compile.dcl
index 6407b67..4857ba9 100644
--- a/Sil/Compile.dcl
+++ b/Sil/Compile.dcl
@@ -7,12 +7,16 @@ from Data.Error import :: MaybeError
from ABC.Assembler import :: Assembler, :: Statement, instance <<< Assembler
-from Sil.Syntax import :: Program, :: Name
+from Sil.Syntax import :: Program, :: Name, :: Expression
+from Sil.Types import :: Type, :: TypeError
:: CompileError
= UndefinedName Name
| VariableLabel
| FunctionOnStack
+ | TypeError TypeError Expression
+ | CouldNotDeduceType Expression
+ | TypeMisMatch Type Expression
| UnknownError
instance toString CompileError