From 1475df9bedc03417708f20d94b5e3db5c80f3036 Mon Sep 17 00:00:00 2001 From: Paul Phillips Date: Wed, 2 May 2012 14:02:04 -0700 Subject: Unanchored regex extractors. This patch is really by Lanny Ripple , but I reworked it because I didn't want to put any more methods onto String. Instead, there is a method on Regex which removes the anchoring quality. """\d\d'"".r.unanchored --- test/files/run/si5045.check | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 test/files/run/si5045.check (limited to 'test/files/run/si5045.check') diff --git a/test/files/run/si5045.check b/test/files/run/si5045.check new file mode 100644 index 0000000000..7e9c1961b7 --- /dev/null +++ b/test/files/run/si5045.check @@ -0,0 +1,6 @@ + extract an exact match 2011-07-15 2011-07-15 + extract from middle of string 2011-07-15 2011-07-15 + extract from middle of string (P2) 2011-07-15 2011-07-15 + extract from middle of string (P3) 2011-07-15 2011-07-15 + copyright example has date Copyright 2011 Copyright 2011 + copyright example missing date No copyright No copyright -- cgit v1.2.3