Author: rahul
Date: Tue Feb 28 16:20:54 2006
New Revision: 381845
URL: http://svn.apache.org/viewcvs?rev=381845&view=rev
Log:
Log warning instead of silently ignoring expressions beyond the first (if there
are more than one).
Modified:
jakarta/commons/proper/jexl/trunk/src/java/org/apache/commons/jexl/ExpressionFactory.java
Modified:
jakarta/commons/proper/jexl/trunk/src/java/org/apache/commons/jexl/ExpressionFactory.java
URL:
http://svn.apache.org/viewcvs/jakarta/commons/proper/jexl/trunk/src/java/org/apache/commons/jexl/ExpressionFactory.java?rev=381845&r1=381844&r2=381845&view=diff
==============================================================================
---
jakarta/commons/proper/jexl/trunk/src/java/org/apache/commons/jexl/ExpressionFactory.java
(original)
+++
jakarta/commons/proper/jexl/trunk/src/java/org/apache/commons/jexl/ExpressionFactory.java
Tue Feb 28 16:20:54 2006
@@ -120,6 +120,14 @@
tree = parser.parse(new StringReader(expr));
}
+ if (tree.jjtGetNumChildren() > 1) {
+ if (log.isWarnEnabled()) {
+ log.warn( "The JEXL Expression created will be a reference"
+ + " to the first expression from the supplied script: \""
+ + expression + "\" " );
+ }
+ }
+
// Must be a simple reference, expression, statement or if, otherwise
// throw an exception.
SimpleNode node = (SimpleNode) tree.jjtGetChild(0);
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]