bolt/deps/llvm-18.1.8/llvm/test/YAMLParser/spec-09-02.test
2025-02-14 19:21:04 +01:00

29 lines
1.2 KiB
Text
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# RUN: yaml-bench -canonical %s 2>&1 | FileCheck %s --strict-whitespace
# CHECK: "as space trimmed\nspecific\L escaped\t none"
## Note: The example was originally taken from Spec 1.1, but the parsing rules
## have been changed since then.
## * The line-separator character '\u2028' is no longer considered a line-break
## character, so the line "...specific\u2028\nescaped..." is now parsed as
## "...specific\L escaped...".
## * The paragraph-separator character '\u2029' is also excluded from line-break
## characters, so the original sequence "escaped\t\\\u2029" is no longer
## considered valid. This is replaced by "escaped\t\\\n" in the test source,
# so the output has changed as well.
## See https://yaml.org/spec/1.2.2/ext/changes/ for details.
##
## Note 2: Different parsers handle this corner case example differently.
## * https://github.com/yaml/libyaml:
## "as space trimmed\nspecific\L\nescaped\t\nnone"
## * https://github.com/yaml/yaml-reference-parser (parser-1.2):
## "as space trimmed\nspecific\L escaped\t none"
## * https://github.com/yaml/yaml-reference-parser (parser-1.3):
## "as space trimmed\nspecific escaped\t none"
"as space
trimmed
specific
escaped \
none"