Closed alehresmann closed 4 years ago
Sorry, but that isn't valid TOML.
Quoting the TOML spec:
Bare keys may only contain ASCII letters, ASCII digits, underscores, and dashes (
A-Za-z0-9_-
). Note that bare keys are allowed to be composed of only ASCII digits, e.g.1234
, but are always interpreted as strings.[examples]
Quoted keys follow the exact same rules as either basic strings or literal strings and allow you to use a much broader set of key names. Best practice is to use bare keys except when absolutely necessary.
Therefore, Héllo
is not a valid TOML key; it must be quoted as "Héllo"
.
Similarly for tables:
Naming rules for tables are the same as for keys (see definition of Keys above).
If you quote these names, you'll see that vim-toml handles it correctly:
Hello,
it looks like not all syntax highlighting works when working with certain characters from utf-8:
see for instance the following example in toml:
I get the following syntax highlighting:
I do highlight that my file was indeed a utf-8 file, as defined by the TOML spec:
$ file -i example.toml
example.toml: text/plain; charset=utf-8