Skip to content

Commit

Permalink
add: CodegenError Eq instance
Browse files Browse the repository at this point in the history
  • Loading branch information
G0nzal0zz committed Jan 19, 2025
1 parent 5938d7c commit 16080b7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/Codegen/Errors.hs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ data CodegenError = CodegenError
{ errorLoc :: AT.SrcLoc,
errorType :: CodegenErrorType
}
deriving (Eq)

-- | Error types for code generation.
data CodegenErrorType
Expand All @@ -31,7 +32,7 @@ data CodegenErrorType
| BreakOutsideLoop
| UnsupportedConversion T.Type T.Type
| UnsupportedGlobalDeclaration AT.Expr
deriving (Show)
deriving (Eq, Show)

instance Show CodegenError where
show :: CodegenError -> String
Expand Down

0 comments on commit 16080b7

Please sign in to comment.