blob: 7b0cf2f6501c5eeb86a0615c877d29b76d3d8f2a (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
definition module Sil.Compile
from StdFile import class <<<
from StdOverloaded import class toString
from Data.Error import :: MaybeError
from ABC.Assembler import :: Assembler, :: Statement, instance <<< Assembler
from Sil.Syntax import :: Program, :: Name, :: Expression
from Sil.Types import :: Type, :: TypeError
:: CompileError
= UndefinedName Name
| UndefinedField Name
| VariableLabel
| FunctionOnStack
| TypeError TypeError Expression
| CouldNotDeduceType Expression
| TypeMisMatch Type Expression
| BasicInitWithoutValue Name
| UnknownError
instance toString CompileError
compile :: Program -> MaybeError CompileError Assembler
|