diff --git a/CHANGELOG.md b/CHANGELOG.md index 45079849..ddda0a25 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,8 +2,12 @@ ## unreleased +- Clarify that comparison for quoted keys is ordinal and doesn't do Unicode + normalization ([#993]) + - Clarify that tables typically cannot be nested infinitely [#1087]). +[#993]: https://github.com/toml-lang/toml/pull/993 [#1087]: https://github.com/toml-lang/toml/pull/1087 ## 1.1.0 / 2025-12-18 diff --git a/toml.md b/toml.md index e4119dcb..1ec0d8be 100644 --- a/toml.md +++ b/toml.md @@ -194,6 +194,20 @@ spelling = "favorite" "spelling" = "favourite" ``` +Quoted keys are considered identical if their code point sequences are the same. +It is possible to create distinct keys that appear visually identical. Doing so +is discouraged: + +```toml +# VALID BUT DISCOURAGED + +# prénom = "Françoise", using pre-composed LATIN SMALL LETTER E WITH ACUTE (U+00E9, NFC) +"pr\xe9nom" = "Françoise" + +# prénom = "Françoise", using COMBINING ACUTE ACCENT (U+0301, NFD) +"pre\u0301nom" = "Françoise" +``` + As long as a key hasn't been directly defined, you may still write to it and to names within it.