diff options
author | Juan J. Martinez <jjm@usebox.net> | 2022-09-10 19:42:50 +0100 |
---|---|---|
committer | Juan J. Martinez <jjm@usebox.net> | 2022-09-10 19:42:50 +0100 |
commit | 5e1de5649a8d2983a1a81e59f47df282e71f9fe6 (patch) | |
tree | 4a0034c398e115b1f13ff47ecc085d8078ec5f7d /src | |
parent | c72455c9f4203ab7b9c617f26ffa7e5fdabf2d5f (diff) | |
download | micro-lang-hs-5e1de5649a8d2983a1a81e59f47df282e71f9fe6.tar.gz micro-lang-hs-5e1de5649a8d2983a1a81e59f47df282e71f9fe6.zip |
Renamed constructor
Diffstat (limited to 'src')
-rw-r--r-- | src/Micro/Compiler.hs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/Micro/Compiler.hs b/src/Micro/Compiler.hs index d27960a..70f442f 100644 --- a/src/Micro/Compiler.hs +++ b/src/Micro/Compiler.hs @@ -23,7 +23,7 @@ data CompState = CompState } deriving (Show) -data Result = CompResult +data Result = Result { -- last resolved type crType :: Maybe A.Type, -- only in last call @@ -31,13 +31,13 @@ data Result = CompResult } typeResult :: Maybe A.Type -> Result -typeResult t = CompResult {crType = t, crExit = Left []} +typeResult t = Result {crType = t, crExit = Left []} errorResult :: [Error] -> Result -errorResult err = CompResult {crType = Nothing, crExit = Left err} +errorResult err = Result {crType = Nothing, crExit = Left err} successResult :: String -> Result -successResult out = CompResult {crType = Nothing, crExit = Right out} +successResult out = Result {crType = Nothing, crExit = Right out} startState :: CompState startState = CompState emptyEnv [] [] |