summaryrefslogtreecommitdiffstats
path: root/llvm/test/YAMLParser/spec-09-22.test
diff options
context:
space:
mode:
authorAlex Lorenz <arphaman@gmail.com>2015-05-13 23:10:51 +0000
committerAlex Lorenz <arphaman@gmail.com>2015-05-13 23:10:51 +0000
commita22b250c6ffaba93b5de2b126eac260585b19dd5 (patch)
treea14a08de72bd30cdc7d6b7ff7c4ddcb5dc774fc5 /llvm/test/YAMLParser/spec-09-22.test
parentaf0494f1585f4d41c4eb9c64930fb077289d1190 (diff)
downloadbcm5719-llvm-a22b250c6ffaba93b5de2b126eac260585b19dd5.tar.gz
bcm5719-llvm-a22b250c6ffaba93b5de2b126eac260585b19dd5.zip
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
Diffstat (limited to 'llvm/test/YAMLParser/spec-09-22.test')
-rw-r--r--llvm/test/YAMLParser/spec-09-22.test14
1 files changed, 10 insertions, 4 deletions
diff --git a/llvm/test/YAMLParser/spec-09-22.test b/llvm/test/YAMLParser/spec-09-22.test
index b95faa50b5d..726358dd5ba 100644
--- a/llvm/test/YAMLParser/spec-09-22.test
+++ b/llvm/test/YAMLParser/spec-09-22.test
@@ -1,6 +1,12 @@
-# RUN: yaml-bench -canonical %s
+# RUN: yaml-bench -canonical %s | FileCheck %s
+# CHECK: !!str "text"
+# CHECK: !!str "text\n"
+# CHECK: !!str "text\n\n"
strip: |-
- text
clip: |
- text…keep: |+
- text

+ text
+clip: |
+ text
+keep: |+
+ text
+
OpenPOWER on IntegriCloud