- edited description
Abbreviated bool values are not parsed as Boolean
Issue #447
invalid
According to https://yaml.org/type/bool.html, boolean
\> may be abbreviated as a single character “y
”/“n
” or “Y
”/“N
”
However, this doesn’t work.
import org.yaml.snakeyaml.Yaml
String x = '''\
b: y
'''.stripIndent()
Yaml yaml = new Yaml()
m = yaml.load(x)
println m['b'].class
gives java.lang.String
, not Boolean
.
SnakeYAML version: 1.23
JDK 8u191
Comments (3)
-
reporter -
reporter Found the last paragraph in documentation. Never mind
-
reporter - changed status to resolved
Documented behavior
- Log in to comment
According to https://yaml.org/type/bool.html, boolean
However, this doesn’t work.
gives
java.lang.String
, notBoolean
.SnakeYAML version:
1.23
JDK 8u191