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)
commita22b250c6ffaba93b5de2b126eac260585b19dd5
treea14a08de72bd30cdc7d6b7ff7c4ddcb5dc774fc5
parentaf0494f1585f4d41c4eb9c64930fb077289d1190
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

llvm-svn: 237314
15 files changed:
llvm/include/llvm/Support/YAMLParser.h
llvm/lib/Support/YAMLParser.cpp
llvm/test/YAMLParser/spec-09-14.test
llvm/test/YAMLParser/spec-09-18.test
llvm/test/YAMLParser/spec-09-19.test
llvm/test/YAMLParser/spec-09-20.test
llvm/test/YAMLParser/spec-09-21.test
llvm/test/YAMLParser/spec-09-22.test
llvm/test/YAMLParser/spec-09-24.test
llvm/test/YAMLParser/spec-09-25.test
llvm/test/YAMLParser/spec-09-26.test
llvm/test/YAMLParser/spec-09-27.test [deleted file]
llvm/test/YAMLParser/spec-09-28.test [deleted file]
llvm/unittests/Support/YAMLParserTest.cpp
llvm/utils/yaml-bench/YAMLBench.cpp