mirror of https://github.com/kdl-org/kdl.git
allow BOM only in the first unicode scalar in a document
This commit is contained in:
parent
13799de32b
commit
49402ccb7b
|
|
@ -53,6 +53,8 @@
|
|||
* Between annotations and the thing they're annotating (`(blah) node (thing)
|
||||
1 y= (who) 2`)
|
||||
* Around `=` for props (`x = 1`)
|
||||
* The BOM is now only allowed as the first character in a document. It was
|
||||
previously treated as generic whitespace.
|
||||
|
||||
### KQL
|
||||
|
||||
|
|
|
|||
4
SPEC.md
4
SPEC.md
|
|
@ -516,6 +516,8 @@ authoritative if something seems to disagree with the text above. The [grammar
|
|||
language syntax](#grammar-language) is defined below.
|
||||
|
||||
```
|
||||
document := bom? nodes
|
||||
|
||||
nodes := (line-space* node)* line-space*
|
||||
|
||||
plain-line-space := newline | ws | single-line-comment
|
||||
|
|
@ -572,7 +574,7 @@ escline := '\\' ws* (single-line-comment | newline | eof)
|
|||
|
||||
newline := See Table (All line-break white_space)
|
||||
|
||||
ws := bom | unicode-space | multi-line-comment
|
||||
ws := unicode-space | multi-line-comment
|
||||
|
||||
bom := '\u{FEFF}'
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue