YAML: Implement block scalar parsing.
authorAlex Lorenz <arphaman@gmail.com>
Wed, 13 May 2015 23:10:51 +0000 (23:10 +0000)
committerAlex Lorenz <arphaman@gmail.com>
Wed, 13 May 2015 23:10:51 +0000 (23:10 +0000)
commitb96942f6ec1c91a4531e7ecf845abdba0e5285f6
tree08abde5057ffad1b25bcc6fc582d0a8536198e8a
parent7c001dac7a65dc2560f116bbd907968c3150193f
YAML: Implement block scalar parsing.

This commit implements the parsing of YAML block scalars.
Some code existed for it before, but it couldn't parse block
scalars.

This commit adds a new yaml node type to represent the block
scalar values.

This commit also deletes the 'spec-09-27' and 'spec-09-28' tests
as they are identical to the test file 'spec-09-26'.

This commit introduces 3 new utility functions to the YAML scanner
class: `skip_s_space`, `advanceWhile` and `consumeLineBreakIfPresent`.

Reviewers: Duncan P. N. Exon Smith

Differential Revision: http://reviews.llvm.org/D9503

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@237314 91177308-0d34-0410-b5e6-96231b3b80d8
15 files changed:
include/llvm/Support/YAMLParser.h
lib/Support/YAMLParser.cpp
test/YAMLParser/spec-09-14.test
test/YAMLParser/spec-09-18.test
test/YAMLParser/spec-09-19.test
test/YAMLParser/spec-09-20.test
test/YAMLParser/spec-09-21.test
test/YAMLParser/spec-09-22.test
test/YAMLParser/spec-09-24.test
test/YAMLParser/spec-09-25.test
test/YAMLParser/spec-09-26.test
test/YAMLParser/spec-09-27.test [deleted file]
test/YAMLParser/spec-09-28.test [deleted file]
unittests/Support/YAMLParserTest.cpp
utils/yaml-bench/YAMLBench.cpp