diff options
author | Camil Staps | 2017-07-20 20:25:25 +0000 |
---|---|---|
committer | Camil Staps | 2017-07-20 20:25:25 +0000 |
commit | bc950badd0655328af7a9886988722809e367d07 (patch) | |
tree | 6411d00c5022b591697c206cc1261dafb8ec8b33 /Sil/Compile.dcl | |
parent | Add checks for locals with type Void (diff) |
Type checking
Diffstat (limited to 'Sil/Compile.dcl')
-rw-r--r-- | Sil/Compile.dcl | 6 |
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 |