commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r1207358 - /commons/proper/jexl/trunk/src/main/java/org/apache/commons/jexl2/Interpreter.java
Date Mon, 28 Nov 2011 16:08:16 GMT
Author: sebb
Date: Mon Nov 28 16:08:15 2011
New Revision: 1207358

URL: http://svn.apache.org/viewvc?rev=1207358&view=rev
Log:
Unnecessary cast and instanceof check

Modified:
    commons/proper/jexl/trunk/src/main/java/org/apache/commons/jexl2/Interpreter.java

Modified: commons/proper/jexl/trunk/src/main/java/org/apache/commons/jexl2/Interpreter.java
URL: http://svn.apache.org/viewvc/commons/proper/jexl/trunk/src/main/java/org/apache/commons/jexl2/Interpreter.java?rev=1207358&r1=1207357&r2=1207358&view=diff
==============================================================================
--- commons/proper/jexl/trunk/src/main/java/org/apache/commons/jexl2/Interpreter.java (original)
+++ commons/proper/jexl/trunk/src/main/java/org/apache/commons/jexl2/Interpreter.java Mon
Nov 28 16:08:15 2011
@@ -675,7 +675,7 @@ public class Interpreter implements Pars
         try {
             return arithmetic.divide(left, right);
         } catch (ArithmeticException xrt) {
-            if (!strict && xrt instanceof ArithmeticException) {
+            if (!strict) {
                 return new Double(0.0);
             }
             JexlNode xnode = findNullOperand(xrt, node, left, right);



Mime
View raw message