import StdBool
import StdList
import StdChar
-import StdFile
-import System.CommandLine
import qualified Text
SingleCharTokens :: Map Char Token
lex :: [Char] -> (Either String Token, [Char])
lex [] = (Right EndOfFileToken, [])
-//Comments
lex ['/':'/':x:rest] = if (x == '\n') (lex rest) (lex ['/':'/':rest])
lex ['/':'*':x1:x2:rest] = if (x1 == '*' && x2 == '/')
(lex rest) (lex ['/':'*':rest])
-//Keyword tokens
lex ['v':'a':'r':rest] = (Right VarToken, rest)
lex ['V':'o':'i':'d':rest] = (Right VoidToken, rest)
lex ['r':'e':'t':'u':'r':'n':rest] = (Right ReturnToken, rest)
lex ['I':'n':'t':rest] = (Right IntTypeToken, rest)
lex ['C':'h':'a':'r':rest] = (Right CharTypeToken, rest)
lex ['B':'o':'o':'l':rest] = (Right BoolTypeToken, rest)
-//Two character tokens
lex [':':':':rest] = (Right DoubleColonToken, rest)
lex ['!':'=':rest] = (Right NotEqualToken, rest)
lex ['<':'=':rest] = (Right LesserEqToken, rest)
lex ['&':'&':rest] = (Right AmpersandsToken, rest)
lex ['|':'|':rest] = (Right PipesToken, rest)
lex ['-':'>':rest] = (Right ArrowToken, rest)
-//One character tokens
-//Value tokens
lex ['\'':x:'\'':rest] = (Right (CharToken x), rest)
lex ['\'':'\\':x:'\'':rest] = case get x EscapeMap of
Just t = (Right (CharToken t), rest)
ReadableABC: False
ReuseUniqueNodes: True
Fusion: False
- Module
- Name: System.CommandLine
- Dir: {Application}/lib/iTasks-SDK/Dependencies/clean-platform/src/libraries/OS-Independent
- Compiler
- NeverMemoryProfile: False
- NeverTimeProfile: False
- StrictnessAnalysis: True
- ListTypes: StrictExportTypes
- ListAttributes: True
- Warnings: True
- Verbose: True
- ReadableABC: False
- ReuseUniqueNodes: True
- Fusion: False
Module
Name: System.IO
Dir: {Application}/lib/iTasks-SDK/Dependencies/clean-platform/src/libraries/OS-Independent
ReadableABC: False
ReuseUniqueNodes: True
Fusion: False
- Module
- Name: System._Pointer
- Dir: {Application}/lib/iTasks-SDK/Dependencies/clean-platform/src/libraries/OS-Independent
- Compiler
- NeverMemoryProfile: False
- NeverTimeProfile: False
- StrictnessAnalysis: True
- ListTypes: StrictExportTypes
- ListAttributes: True
- Warnings: True
- Verbose: True
- ReadableABC: False
- ReuseUniqueNodes: True
- Fusion: False
Module
Name: Text
Dir: {Application}/lib/iTasks-SDK/Dependencies/clean-platform/src/libraries/OS-Independent
ReadableABC: False
ReuseUniqueNodes: True
Fusion: False
- Module
- Name: System.OS
- Dir: {Application}/lib/iTasks-SDK/Dependencies/clean-platform/src/libraries/OS-Linux-64
- Compiler
- NeverMemoryProfile: False
- NeverTimeProfile: False
- StrictnessAnalysis: True
- ListTypes: StrictExportTypes
- ListAttributes: True
- Warnings: True
- Verbose: True
- ReadableABC: False
- ReuseUniqueNodes: True
- Fusion: False
Module
Name: _SystemDynamic
Dir: {Application}/lib/iTasks-SDK/Patches/Dynamics