From 466a7fc0c02ba371142377b33534dcc98d0e904e Mon Sep 17 00:00:00 2001 From: Johannes Schindelin Date: Thu, 17 Oct 2013 15:06:09 -0500 Subject: [PATCH] Be more verbose when complaining about a non-trivial regex In particular when constructing regular expressions before compiling them, it is a good idea to state which exact expression is non-trivial when complaining about it. Signed-off-by: Johannes Schindelin --- classpath/java/util/regex/Pattern.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/classpath/java/util/regex/Pattern.java b/classpath/java/util/regex/Pattern.java index 9c0bd680fd..65a4617fce 100644 --- a/classpath/java/util/regex/Pattern.java +++ b/classpath/java/util/regex/Pattern.java @@ -40,7 +40,7 @@ public class Pattern { if (! trivial(pattern)) { throw new UnsupportedOperationException - ("only trivial regular expressions are supported so far"); + ("only trivial regular expressions are supported so far (" + pattern + ")"); } }