Skip to content

Commit

Permalink
clarify updateDefaultParams
Browse files Browse the repository at this point in the history
  • Loading branch information
metagn committed Oct 4, 2024
1 parent 701c8c1 commit aad5a19
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion compiler/semcall.nim
Original file line number Diff line number Diff line change
Expand Up @@ -683,7 +683,9 @@ proc updateDefaultParams(c: PContext, call: PNode) =
let formal = calleeParams[i].sym
let def = formal.ast
if def == nil:
# inserted param but not default value
# this is true if and only if this is an inserted empty varargs param,
# in which case we don't do anything
# every other case should be an inserted default value
continue
if nfDefaultRefsParam in def.flags: call.flags.incl nfDefaultRefsParam
# mirrored with sigmatch:
Expand Down

0 comments on commit aad5a19

Please sign in to comment.