tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 45691] Jasper creates duplicate variable names
Date Tue, 26 Aug 2008 14:49:41 GMT
https://issues.apache.org/bugzilla/show_bug.cgi?id=45691





--- Comment #2 from Stefan Birkner <Stefan.Birkner@immobilienscout24.de>  2008-08-26
07:49:41 PST ---
Created an attachment (id=22483)
 --> (https://issues.apache.org/bugzilla/attachment.cgi?id=22483)
Patch to be applied to the package org.apache.jasper.compiler

This patch changes two classes: org.apache.jasper.compiler.Generator and
org.apache.jasper.compiler.Node.

Instead of creating the variable names of NamedAtttributes when parsing the JSP
code, the names are created when the Generator generates the java code.

The Generator class has two additional members: an HashMap<NamedAttribute,
String> variableNamesOfNamedAttributes, which stores the mapping between
NamedAttributes and there variable names, and a variableNameCounter, which is
used to create the variables' names. The new method
getVariableName(NamedAttribute) returns the variable names.

The member temporaryVariableName and its getter getTemporaryVariableName() are
removed from the node class.


-- 
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: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message