camel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Claus Ibsen (JIRA)" <j...@apache.org>
Subject [jira] Created: (CAMEL-3052) Simple binary operators - Prefer numeric types over String
Date Thu, 12 Aug 2010 15:31:47 GMT
Simple binary operators - Prefer numeric types over String
----------------------------------------------------------

                 Key: CAMEL-3052
                 URL: https://issues.apache.org/activemq/browse/CAMEL-3052
             Project: Apache Camel
          Issue Type: Improvement
          Components: camel-core
    Affects Versions: 2.4.0
            Reporter: Claus Ibsen
            Assignee: Claus Ibsen
             Fix For: 2.5.0


If you use Simple for comparison and have

{code}
simple("${in.header.foo} > 100") 
{code}
Then the type of foo is used first. And if that type is a String, then you compare with "100"
and not the numeric value of 100.
In those cases we should prefer the numeric type of the right hand side so we do a numeric
vs. numeric comparison first.

As any thing can be converted to String we should prefer String types last.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message