We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b8a7190 commit 0f42c9cCopy full SHA for 0f42c9c
Rubberduck.Parsing/Symbols/BoundExpressionVisitor.cs
@@ -48,9 +48,10 @@ private void Visit(
48
bool isAssignmentTarget,
49
bool hasExplicitLetStatement)
50
{
51
- if (isAssignmentTarget && expression.Context.Parent is VBAParser.IndexExprContext)
+ if (isAssignmentTarget && expression.Context.Parent is VBAParser.IndexExprContext && !expression.ReferencedDeclaration.IsArray)
52
53
// 'SomeDictionary' is not the assignment target in 'SomeDictionary("key") = 42'
54
+ // ..but we want to treat array index assignment as assignment to the array itself.
55
isAssignmentTarget = false;
56
}
57
0 commit comments