You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I took a look at this library today, and it appears that it is not actually a correct implementation of TOML 1.0.0. I tried running some of the tests in https://github.com/BurntSushi/toml-test , using a janky racket back-end to spit out JSON encodings. While this back-end is very incomplete, the resulting test failures suggest that your TOML library is not correctly parsing a bunch of the different TOML 1.0.0 string forms. Here's one example input from the test library:
backspace = 'This string has a \b backspace character.'
tab = 'This string has a \t tab character.'
newline = 'This string has a \n new line character.'
formfeed = 'This string has a \f form feed character.'
carriage = 'This string has a \r carriage return character.'
slash = 'This string has a \/ slash character.'
backslash = 'This string has a \\ backslash character.'
It produces this output:
(root ("backspace" . "Parser Error: invalid literal or str")
("tab" . "Parser Error: invalid literal or str")
("newline" . "Parser Error: invalid literal or str")
("formfeed" . "Parser Error: invalid literal or str")
("carriage" . "Parser Error: invalid literal or str")
("slash" . "Parser Error: invalid literal or str")
("backslash" . "Parser Error: invalid literal or str"))
Here's another one:
# Single ' should be allowed.
oneline = '''This string has a ' quote character.'''
# A newline immediately following the opening delimiter will be trimmed.
firstnl = '''
This string has a ' quote character.'''
# All other whitespace and newline characters remain intact.
multiline = '''
This string
has ' a quote character
and more than
one newline
in it.'''
it produces this error:
(root
("oneline" . "Parser Error: invalid literal or str")
("firstnl" . "Parser Error: invalid literal or str")
("multiline" . "Parser Error: invalid literal or str"))
The text was updated successfully, but these errors were encountered:
I took a look at this library today, and it appears that it is not actually a correct implementation of TOML 1.0.0. I tried running some of the tests in https://github.com/BurntSushi/toml-test , using a janky racket back-end to spit out JSON encodings. While this back-end is very incomplete, the resulting test failures suggest that your TOML library is not correctly parsing a bunch of the different TOML 1.0.0 string forms. Here's one example input from the test library:
It produces this output:
Here's another one:
it produces this error:
The text was updated successfully, but these errors were encountered: