aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJason Tsay <jasontsay@google.com>2011-07-15 10:27:45 -0700
committerJason Tsay <jasontsay@google.com>2011-07-15 10:29:58 -0700
commit9839e0f23e8ae8e31f8ccb6550737597122044ff (patch)
treebbf0b02ae00a8d4f450c8f00157b39f88a0983fd
parenteae51d647d3da8bbb4ab8ab2ef1276bffd785437 (diff)
downloadprolog-cafe-9839e0f23e8ae8e31f8ccb6550737597122044ff.tar.gz
Turns on multiline matching for regex_compileHEADmaster
Now the pattern generated from regex_compile will match on a line-by-line basis, useful for matching a pattern in a multi-line commit message. Change-Id: I3db9ac5f9597c360fc7600ce3b33dfe0cda7d90e
-rw-r--r--src/builtin/PRED_regex_compile_2.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/builtin/PRED_regex_compile_2.java b/src/builtin/PRED_regex_compile_2.java
index 142234f..5c4ef37 100644
--- a/src/builtin/PRED_regex_compile_2.java
+++ b/src/builtin/PRED_regex_compile_2.java
@@ -37,7 +37,7 @@ public class PRED_regex_compile_2 extends Predicate.P2 {
if (!a1.isSymbol()) {
throw new IllegalTypeException(this, 1, "atom", a1);
}
- Pattern pattern = Pattern.compile(a1.name());
+ Pattern pattern = Pattern.compile(a1.name(), Pattern.MULTILINE);
if (!a2.unify(new JavaObjectTerm(pattern), engine.trail)) {
return engine.fail();