yaml: more examples
[protos/libecoli.git] / examples / parse-yaml / cross.yaml
diff --git a/examples/parse-yaml/cross.yaml b/examples/parse-yaml/cross.yaml
new file mode 100644 (file)
index 0000000..e6e35fa
--- /dev/null
@@ -0,0 +1,16 @@
+# matches "x", "x + x", "x + x + x", ...
+&term
+id: term
+type: or
+children:
+- type: seq
+  children:
+  - &value
+    id: value
+    type: str
+    string: x
+  - id: operator
+    type: str
+    string: +
+  - *term
+- *value