S-expressions: Difference between revisions
Content added Content deleted
Line 3,083: | Line 3,083: | ||
atom s@('"' : _) = |
atom s@('"' : _) = |
||
fromMaybe (List []) (maybeRead ("String " <> s)) |
fromMaybe (List []) (maybeRead ("String " <> s)) |
||
atom s = |
atom s = |
||
headDef (List []) $ |
|||
where |
|||
⚫ | |||
firstParse (x : _) = x |
|||
maybeRead |
|||
⚫ | |||
⚫ | |||
⚫ | |||
maybeRead |
|||
) |
|||
(<> (' ' : s)) |
|||
headDef :: a -> [a] -> a |
|||
⚫ | |||
headDef d [] = d |
|||
⚫ | |||
headDef _ (x : _) = x |
|||
maybeRead :: String -> Maybe Val |
maybeRead :: String -> Maybe Val |