diff options
author | Josh Rahm <joshuarahm@gmail.com> | 2024-08-24 13:55:41 -0600 |
---|---|---|
committer | Josh Rahm <joshuarahm@gmail.com> | 2024-08-24 13:55:41 -0600 |
commit | f1128c7c60809d1e96009eaed98c0756831fe29f (patch) | |
tree | 3cc1957c7436e9efb1d26548b285fa3449574c3a /src/Language/Fiddle/Parser.hs | |
parent | 21f879cf2ac5f51f827fe76c55915e56edc113b8 (diff) | |
download | fiddle-f1128c7c60809d1e96009eaed98c0756831fe29f.tar.gz fiddle-f1128c7c60809d1e96009eaed98c0756831fe29f.tar.bz2 fiddle-f1128c7c60809d1e96009eaed98c0756831fe29f.zip |
Add Stage3 compliation.
I think this is the last phase before sending the refined AST to the
backend compiler to be processed.
Diffstat (limited to 'src/Language/Fiddle/Parser.hs')
-rw-r--r-- | src/Language/Fiddle/Parser.hs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/Language/Fiddle/Parser.hs b/src/Language/Fiddle/Parser.hs index dc479d1..37ef34e 100644 --- a/src/Language/Fiddle/Parser.hs +++ b/src/Language/Fiddle/Parser.hs @@ -28,6 +28,7 @@ type P = ParsecT S () Identity type A = Commented SourceSpan type Pa (a :: Stage -> (Type -> Type) -> Type -> Type) = P (a 'Stage1 F (Commented SourceSpan)) +type PaS (a :: (Type -> Type) -> Type -> Type) = P (a F (Commented SourceSpan)) comment :: P Comment comment = @@ -139,7 +140,7 @@ objTypeDecl = <*> optionMaybe (tok TokColon *> registerBody) ) -modifier :: Pa Modifier +modifier :: PaS Modifier modifier = withMeta $ ModifierKeyword @@ -278,7 +279,7 @@ printNext = do traceM $ "NextToken: " ++ show t return () -ident :: Pa Identifier +ident :: PaS Identifier ident = withMeta $ token $ \case |