Project
IntelliJ IDEA
Priority
Normal
Type
Bug
Fix versions
No Fix versions
State
Open
Assignee
Peter Gromov
Subsystem
Template Languages. Velocity
Affected versions
No Affected versions
Fixed in build
No Fixed in build
  • Created by   Andrew Lynch
    3 years ago (10 Nov 2008 10:11)
  • Updated by   Peter Gromov
    9 months ago (28 Apr 2011 20:42)
  • Jira: IDEADEV-33387
    (history, comments)
 
IDEA-46589 Find usages does not correctly detect usage of a property / method in templates consistently
0
Issue is visible to: All Users
  The issue is visible to the selected user group only
Say I have the following code in SomeAction :

public Map getSystemPropertiesHtml() {
...
}


And then in my velocity template I declare :
#* @vtlvariable name="action" type="SomeAction" *#

$action.getSystemPropertiesHtml()

$action.systemPropertiesHtml


neither usage will be found.

However, it will work if I use a set directive:

#* @vtlvariable name="action" type="SomeAction" *#
#set($foo = $action.getSystemPropertiesHtml())

$action.getSystemPropertiesHtml()

$action.systemPropertiesHtml


This doesn't seem to be the only way to trigger it (occasionally it randomly _just_ works); it appears the indexing of usages within velocity files is quite flaky and broken.





Environment: Intellij 8 on Mac OS X 10.4
Comments (1)
 
History
 
Linked Issues (?)
 
Andrew Lynch
  Andrew Lynch
10 Nov 2008 10:16
3 years ago
Actually, perhaps it isn't the assignment that corrects it; it seems to work fine for new files. Perhaps indexing of existing files is broken?