summaryrefslogtreecommitdiff
path: root/testdata/testinput20
diff options
context:
space:
mode:
authorph10 <ph10@6239d852-aaf2-0410-a92c-79f79f948069>2015-08-18 10:34:05 +0000
committerph10 <ph10@6239d852-aaf2-0410-a92c-79f79f948069>2015-08-18 10:34:05 +0000
commite4b2532cb5204ede16f39aca7c63a97ff380094b (patch)
tree3215cf19e650395e5c828932d38dacc1fc076a05 /testdata/testinput20
parent060fab17340fc4b8615bc4ee486f269ed8b799c8 (diff)
downloadpcre2-e4b2532cb5204ede16f39aca7c63a97ff380094b.tar.gz
Runtime UTF checks now take not of the starting offset.
git-svn-id: svn://vcs.exim.org/pcre2/code/trunk@348 6239d852-aaf2-0410-a92c-79f79f948069
Diffstat (limited to 'testdata/testinput20')
-rw-r--r--testdata/testinput2062
1 files changed, 62 insertions, 0 deletions
diff --git a/testdata/testinput20 b/testdata/testinput20
new file mode 100644
index 0000000..3a8f06e
--- /dev/null
+++ b/testdata/testinput20
@@ -0,0 +1,62 @@
+# This set of tests exercises the serialization/deserialization functions in
+# the library. It does not use UTF or JIT.
+
+#forbid_utf
+
+# Compile several patterns, push them onto the stack, and then write them
+# all to a file.
+
+#pattern push
+
+/(?<NAME>(?&NAME_PAT))\s+(?<ADDR>(?&ADDRESS_PAT))
+ (?(DEFINE)
+ (?<NAME_PAT>[a-z]+)
+ (?<ADDRESS_PAT>\d+)
+ )/x
+/^(?:((.)(?1)\2|)|((.)(?3)\4|.))$/i
+
+#save testsaved1
+
+# Do it again for some more patterns.
+
+/(*MARK:A)(*SKIP:B)(C|X)/mark
+/(?:(?<n>foo)|(?<n>bar))\k<n>/dupnames
+
+#save testsaved2
+#pattern -push
+
+# Reload the patterns, then pop them one by one and check them.
+
+#load testsaved1
+#load testsaved2
+
+#pop info
+ foofoo
+ barbar
+
+#pop mark
+ C
+ D
+
+#pop
+ AmanaplanacanalPanama
+
+#pop info
+ metcalfe 33
+
+# Check for an error when different tables are used.
+
+/abc/push,tables=1
+/xyz/push,tables=2
+#save testsaved1
+
+#pop
+ xyz
+
+#pop
+ abc
+
+#pop should give an error
+ pqr
+
+# End of testinput20