diff options
author | Jed Barber <jjbarber@y7mail.com> | 2014-02-05 11:33:00 +1100 |
---|---|---|
committer | Jed Barber <jjbarber@y7mail.com> | 2014-02-05 11:33:00 +1100 |
commit | 8ef39061d5e5967fb14c3452c1f1e43b9b79b4c5 (patch) | |
tree | 39f869c2750bfb02ffe5493efddb3f2c3a901df0 | |
parent | b9af0635a21b0cdb92be8a92f25c7cf5439774a6 (diff) |
Started writing Fractran parser in parsec
-rw-r--r-- | Fractran/Parser.hs | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/Fractran/Parser.hs b/Fractran/Parser.hs new file mode 100644 index 0000000..7cbea11 --- /dev/null +++ b/Fractran/Parser.hs @@ -0,0 +1,19 @@ +module Parser ( + FractranProgram(..), + + parseFractran + ) where + + +import Text.Combinators.Parsec + + + +data FractranProgram = FractranProgram { fractions :: [(Int,Int)] } + + + +parseFractran :: String -> Either ParseError FractranProgram +parseFractran = parse fractran "error" + + |