Skip to content

Commit

Permalink
Remember to set the call expression in ast_context when entering them…
Browse files Browse the repository at this point in the history
… in file resolve.
  • Loading branch information
DanielGavin committed Oct 5, 2024
1 parent ca2b55c commit a18728a
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/server/file_resolve.odin
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,16 @@ resolve_node :: proc(node: ^ast.Node, data: ^FileResolveData) {
case ^Paren_Expr:
resolve_node(n.expr, data)
case ^Call_Expr:
old_call := data.ast_context.call

data.position_context.call = n
data.ast_context.call = n

defer {
data.position_context.call = old_call
data.ast_context.call = old_call
}

resolve_node(n.expr, data)

for arg in n.args {
Expand Down

0 comments on commit a18728a

Please sign in to comment.