[ 
https://issues.apache.org/jira/browse/VELOCITY-644?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12650057#action_12650057
 ] 

Byron Foster commented on VELOCITY-644:
---------------------------------------

I actually snuck in a small change.  When in strict mode and a reference method 
was called on a null value, like $NULL.foo,  then ASTReference would throw a 
MethodInvocationException.  There were two problems with this.  The first was 
that really the MethodInvocationException is intended for errors that occur 
while calling the method, like an exception being thrown form within the 
method, and as such the wording of the error message was not appropriate for 
$NULL.foo, and was misleading.  The second is that this would cause a redundant 
error message to be logged.  I think too much info is just as bad as too little 
:)  So... I changed the case of $NULL.foo to throw a VelocityException, and I 
Modified StrictReferenceTestCase to handle this change.

> Wrong template name in Exception Message
> ----------------------------------------
>
>                 Key: VELOCITY-644
>                 URL: https://issues.apache.org/jira/browse/VELOCITY-644
>             Project: Velocity
>          Issue Type: Bug
>          Components: Engine
>    Affects Versions: 1.6-beta1
>            Reporter: Byron Foster
>         Attachments: fix644.patch
>
>
> If a reference within a macro causes an Exception, and the macro is defined 
> in a different file, then the Exception message thrown by Velocity reports 
> the name of the calling template file, and not the file that defines the 
> macro.  However, the column number and line number are correct for the macro 
> file.

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


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to