jakarta-taglibs-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 47428] JSTL converts BigDecimal to Long
Date Mon, 29 Jun 2009 17:40:13 GMT
https://issues.apache.org/bugzilla/show_bug.cgi?id=47428





--- Comment #5 from Kris Schneider <kris@dotech.com>  2009-06-29 10:40:11 PST ---
Maybe you can provide some more detail on exactly what you're doing. Here's a
test page, coerce.jsp (webapps/ROOT):

<%@ page contentType="text/plain" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<% pageContext.setAttribute("decimal", new java.math.BigDecimal("0.01")); %>
decimal: ${decimal}
decimal == 0: ${decimal == 0}
<c:if test="${decimal == 0}">true</c:if>

TC 5.0.28
decimal: 0.01
decimal == 0: false

Notice that "true" does *not* get output.

Hang on, is this exactly what you have in your page:

<c:if test="{foo==0}">

Because it should be this:

<c:if test="${foo==0}">

This discussion should also be moved to taglibs-user<<at>>jakarta.apache.org

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: taglibs-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: taglibs-dev-help@jakarta.apache.org


Mime
View raw message