Commit Graph

52 Commits

Author SHA1 Message Date
Kat Marchán bbe7bd9057
allow eof termination for single line comments
Ref: https://github.com/kdl-org/kdl/issues/121
2021-09-02 15:24:45 -07:00
Kat Marchán 2e42c4c0ec
Change URIs to URLs for clarity (#125) 2021-09-02 15:10:03 -07:00
Kat Marchán a44fcbb1d4
add type annotation info to spec (#123)
Fixes: https://github.com/kdl-org/kdl/issues/106
2021-09-02 09:23:51 -07:00
Kat Marchán 7c54aae64f
actually add child node spec to spec itself
Fixes: https://github.com/kdl-org/kdl/issues/59
2021-08-31 23:08:12 -07:00
Kat Marchán 129812543f
prevent the three "keywords" from being used as bare identifiers (#117)
Fixes: https://github.com/kdl-org/kdl/issues/114
2021-08-31 21:47:59 -07:00
Kat Marchán 37c0a38baa
allow _ in post-decimal-point section (#118)
Fixes: https://github.com/kdl-org/kdl/issues/69
2021-08-31 20:39:17 -07:00
Kat Marchán 3f739cad42
make / illegal in identifiers
Fixes: https://github.com/kdl-org/kdl/issues/75
2021-08-31 20:09:45 -07:00
Kat Marchán 04a84a72ec
link to other specs 2021-08-31 19:38:26 -07:00
Kat Marchán 34c6592f09
remove () from identifiers so we can use it for KQL (#108) 2021-08-31 17:09:57 -07:00
Tab Atkins Jr 9e35601c91
Partially revert #99 (#100)
6704988633 disallowed identifiers from ever starting with a sign character. This disallowed idents like `-`, or like the CSS `--foo` properties.

This change instead allows an ident to start with a sign character, so long as the *second* character isn't a digit.

I also tweaked the prose definition of identifier to talk about this restriction.
2021-08-24 14:57:03 -07:00
Kat Marchán 6704988633
identifiers should never look like numbers (#99) 2021-08-24 09:10:08 -07:00
Kat Marchán 5883435297
fix(grammar): allow whitespace before a node-terminator (#98)
kudos to @lucretiel for spotting this one.
2021-08-21 18:05:53 -07:00
Serafina Brocious e7147cf4ac
Fixed inconsistency between spec wording and BNF (#88) 2021-04-18 20:19:34 -07:00
Serafina Brocious 15aff6a309
Added optional sign to all number syntaxes (#87) 2021-04-18 20:19:21 -07:00
Daniel Smith 9ceb0ed8d4
Possible typo in "Escapes" table (#72)
The maximum unicode code point is `10FFFF` but in the escapes table it states code points can only go up to `10FFF`. I think this is an error, since most emojis are well above that number, and other languages allow escapes up to `10FFFF`
2021-01-11 12:08:03 -08:00
Daniel Smith 1f293c280b
Add forwardlash to escapes table (#73)
I noticed this was a valid escape char in the rust implementation. Not sure if this was intended.
2021-01-11 12:07:28 -08:00
Hannah Kolbeck 1cf1fd0597
Correct description of the raw string format (#71) 2021-01-08 21:09:11 -08:00
Lars Willighagen 89b52b2145
Fill in string escapes table (#60) 2020-12-29 11:27:37 -08:00
hclarke 3da011acbc
Update SPEC.md (#57)
this does a few things with identifiers and strings:

- removes `"` from the set of identifier characters, to prevent ambiguity with string
- adds `bare-identifier` and `escaped-string` non-terminals (i think less mixing of terminal/non-terminal is easier to read?)
- moves string ahead of bare-identifier in identifier, for easier implementation with ordered-choice parsers
- moves raw-string into string, so you can have raw-string identifiers
2020-12-26 18:03:32 -08:00
hclarke 81fad70856
Fixed escape table formatting (#44) 2020-12-22 14:33:39 -08:00
Kat Marchán cf341eac91
more blabber 2020-12-18 22:58:09 -08:00
Kat Marchán 60bcfdf926
require terminator after node-children too 2020-12-18 22:56:27 -08:00
Kat Marchán b30b0cf93a
messing with nodes some more 2020-12-18 21:32:40 -08:00
Kat Marchán dfc1441ec9
more node and nodes fixes 2020-12-18 20:06:11 -08:00
Kat Marchán 42672c1701
forgot eof 2020-12-18 19:31:44 -08:00
Kat Marchán b2a4610742
fix slashdash whitespace 2020-12-18 19:15:48 -08:00
Kat Marchán 3de6d3c095
version 2020-12-18 17:48:46 -08:00
Kat Marchán cc169da2c2
clean up node grammar + allow slashdash spaces 2020-12-18 17:47:36 -08:00
Kat Marchán 144f8d775f
spec out nested multiline comments 2020-12-18 17:43:14 -08:00
Kat Marchán 0f3c494235
completely reserve <>
Fixes: #35
2020-12-18 16:25:05 -08:00
Kat Marchán 1b9d878885
fix single-line-comment 2020-12-18 12:55:06 -08:00
Kat Marchán 6617e2ad47
fix code point 2020-12-18 12:55:06 -08:00
Kat Marchán 4955517118
updated grammar for identifier 2020-12-18 12:55:06 -08:00
Kat Marchán 3f5d405e58
add spec for slashdash 2020-12-18 12:55:05 -08:00
Tab Atkins Jr 980eccecfb
typo (#40) 2020-12-17 20:17:39 -08:00
Kat Marchán 92bdcb1a4d
heh 2020-12-16 22:09:11 -08:00
Kat Marchán 13e203b928
spec out Values 2020-12-16 21:34:22 -08:00
Kat Marchán 0233d5557a
work on props and args 2020-12-16 20:09:27 -08:00
Kat Marchán 1bfbe78022
nicer formatting for unicode in grammar 2020-12-16 12:07:56 -08:00
Kat Marchán 5cf6a5a276
bring back bom-as-ws (#34)
* bring back bom-as-ws

* Update SPEC.md

Co-authored-by: Lily Ballard <lily@sb.org>

Co-authored-by: Lily Ballard <lily@sb.org>
2020-12-15 23:15:50 -08:00
Kat Marchán 32f38622ee
clarify guidance around file encoding and BOMs 2020-12-15 22:28:06 -08:00
Lily Ballard f55ac50a89
Tighten up slashdash definition (#33)
Previously slashdash was allowed anywhere `ws` was, and could be
followed by any legal slashdashable token regardless of position. This
caused some ambiguous parsing and enabled constructions we really don't
want.

The new version simply allows a slashdash to preceed each commentable
token, thus restricting its use to locations where the token is
otherwise valid.
2020-12-15 22:00:17 -08:00
Lily Ballard 3c36d683ab
Remove VT from newline definition (#32)
The Unicode standard listed VT in its table in §5.8 but that was just a
table of acronyms, and VT was only listed because Microsoft Word used it
as a line separator. VT is not part of its recommendation for characters
to treat as line terminators.
2020-12-15 21:52:44 -08:00
Kat Marchán 870339c69e
unicode spacing support 2020-12-15 21:49:56 -08:00
Kat Marchán fa60bc63e9
newline -> unicode newlines
Fixes: #30
2020-12-15 21:33:55 -08:00
Kat Marchán 3ed2f0aa27
be a bit more specific about ordering + add line continuations 2020-12-15 21:18:48 -08:00
Kat Marchán 951eed8f43
remove the 'values are just number-indexed properties' feature 2020-12-15 20:50:35 -08:00
Kat Marchán b4067bdfad
write down some design principles to get started with 2020-12-15 18:46:40 -08:00
Kat Marchán bb9562e4fc
add some fixmes to the grammar 2020-12-15 18:46:40 -08:00
Kat Marchán 0092ad84db
wip long-form spec stuff 2020-12-14 22:49:27 -08:00