Get variable value with static code analysis

Hi, right now I am using the references of a PsiExpression and traversing through all of them to get the actual value of the variable. Given that I have the type of variable and the PsiExpression of one of its instances, is there any other way to get the value instead of traversing through all the references?
Its Java code by the way.
Thanks

1 comment
Comment actions Permalink

You can use the classes DfaVariableValue for extracting the value of a variable at Runtime.

0

Please sign in to leave a comment.