Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
fix local false positive
  • Loading branch information
ryaneberly committed Jul 19, 2017
1 parent c86009f commit ffd72f2
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,9 @@ public void expression(final CFExpression expression, final Context context, fin
} else if (expression instanceof CFVarDeclExpression) {
final String name = ((CFVarDeclExpression) expression).getName();
final int lineNo = expression.getLine() + context.startLine() - 1;
addLocalVariable(name, lineNo);
if(!scopes.isCFScoped(name)){
addLocalVariable(name, lineNo);
}
} else if (expression instanceof CFIdentifier) {
final String name = ((CFIdentifier) expression).getName();
if(name != null){
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
<cfcomponent>
<cffunction name="foo">
<cfset var local = {}>
<cfset local.stEditor = 123>
</cffunction>
</cfcomponent>
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[ {
"totalfiles" : 0
}, {
"totalsize" : 0
} ]

0 comments on commit ffd72f2

Please sign in to comment.