aboutsummaryrefslogtreecommitdiff
path: root/src/Fun/Tree.hs
diff options
context:
space:
mode:
Diffstat (limited to 'src/Fun/Tree.hs')
-rw-r--r--src/Fun/Tree.hs11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/Fun/Tree.hs b/src/Fun/Tree.hs
index 28434cc..26b415f 100644
--- a/src/Fun/Tree.hs
+++ b/src/Fun/Tree.hs
@@ -4,12 +4,15 @@ import Fun.Typer
data Visibility = PublicVisibility | PrivateVisibility
deriving Show
-data FunctionFlag = FunctionInline | FunctionDeprecated | FunctionUnknown
+-- TODO: Actually enforce danger-* in syntax-check
+data FunctionFlag = FunctionInline | FunctionDeprecated | FunctionDangerVoid | FunctionDangerAsm | FunctionUnknown
deriving Show
instance Read FunctionFlag where
- readsPrec _ "inline" = [(FunctionInline, "")]
- readsPrec _ "deprecated" = [(FunctionDeprecated, "")]
- readsPrec _ _ = [(FunctionUnknown, "")]
+ readsPrec _ "inline" = [(FunctionInline, "")]
+ readsPrec _ "deprecated" = [(FunctionDeprecated, "")]
+ readsPrec _ "danger-void" = [(FunctionDangerVoid, "")]
+ readsPrec _ "danger-asm" = [(FunctionDangerAsm, "")]
+ readsPrec _ _ = [(FunctionUnknown, "")]
data Tree = Tree [Program]
deriving Show