]> Witch of Git - ess/log
ess
7 years agoImprove the number parser
Caleb Jones [Thu, 22 Dec 2016 06:43:56 +0000 (01:43 -0500)]
Improve the number parser

Instead of redoing all the number extraction ourselves, we now reuse the
number parsing code built into Rust. We simply recognize things that
look like numbers, and pass the string into the appropriate number
parsing function.

7 years agoRemove the indirection introduced by separating Atom from Sexp
Caleb Jones [Thu, 22 Dec 2016 06:07:03 +0000 (01:07 -0500)]
Remove the indirection introduced by separating Atom from Sexp

7 years agoChange parse to parse multiple expressions and add parse_one
Caleb Jones [Tue, 20 Dec 2016 22:35:59 +0000 (17:35 -0500)]
Change parse to parse multiple expressions and add parse_one

7 years agoChange parse to return a ParseError instead of ()
Caleb Jones [Tue, 20 Dec 2016 22:10:25 +0000 (17:10 -0500)]
Change parse to return a ParseError instead of ()

7 years agoAdd more tests
Caleb Jones [Wed, 14 Dec 2016 07:24:04 +0000 (02:24 -0500)]
Add more tests

7 years agoAdd parsing for characters
Caleb Jones [Wed, 14 Dec 2016 07:06:23 +0000 (02:06 -0500)]
Add parsing for characters

7 years agoAdd tests for parsing number and symbol
Caleb Jones [Wed, 14 Dec 2016 06:56:48 +0000 (01:56 -0500)]
Add tests for parsing number and symbol

Fix a bug in number parsing where it would accept invalid numbers like
123q.

7 years agoAdd an extremely basic s-expression parser using nom
Caleb Jones [Wed, 14 Dec 2016 06:38:53 +0000 (01:38 -0500)]
Add an extremely basic s-expression parser using nom