diff options
author | Camil Staps | 2017-07-27 23:32:59 +0200 |
---|---|---|
committer | Camil Staps | 2017-07-27 23:32:59 +0200 |
commit | c23b7cd159af38f588ce4214d6ad37ceadf3c1a6 (patch) | |
tree | 66dc800514550a3729fe3e9578fb6fe00f18bfa1 /sil.icl | |
parent | Don't allow tuples with arity > 32 (ABC-machine limitation) (diff) |
Centralise errors (needed for positional errors #5)
Diffstat (limited to 'sil.icl')
-rw-r--r-- | sil.icl | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -23,7 +23,7 @@ import ABC.Assembler from Sil.Check import :: CheckError, checkProgram import qualified Sil.Compile as SC -from Sil.Compile import :: CompileError, instance toString CompileError +import Sil.Error import Sil.Parse from Sil.Syntax import :: Program import Sil.Util.Parser @@ -119,7 +119,7 @@ where <|> item "--generate" *> pure (\cli -> {cli & generate=True}) <|> item "--run" *> pure (\cli -> {cli & run=True}) <|> (satisfy isFilename >>= \name -> pure (\cli -> {cli & inputfile=name})) - <?> Invalid "command line argument" opt + <?> P_Invalid "command line argument" opt ) isFilename :: (String -> Bool) @@ -142,4 +142,4 @@ where <<< f (Ok a) = f <<< a <<< f (Error e) = f <<< e -instance <<< CompileError where <<< f e = f <<< toString e +instance <<< Error where <<< f e = f <<< toString e |