Skip to content

fix: arity checking of call expression arguments - #386

Merged
DeveloperC286 merged 1 commit into
mainfrom
claude/arity-checking-arguments-gu4ewf
Sep 6, 2026
Merged

fix: arity checking of call expression arguments#386
DeveloperC286 merged 1 commit into
mainfrom
claude/arity-checking-arguments-gu4ewf

Conversation

@DeveloperC286

@DeveloperC286 DeveloperC286 commented Sep 6, 2026

Copy link
Copy Markdown
Owner

No description provided.

@DeveloperC286 DeveloperC286 changed the title Add validation for function call argument count fix: arity checking of call expression arguments Sep 6, 2026
Zipping the arguments with the parameters silently truncated to the
shorter of the two. Calling with too few arguments left the unbound
parameters resolving to Null, whilst extra arguments were discarded
without ever being evaluated, so their side effects never ran.

Compare the counts before binding and error with "Wrong number of
arguments, want=2, got=1." instead. The check runs before the
environment is pushed, so a rejected call leaves no scope behind.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WVqA23HZyr13UowhjHjNEt
@DeveloperC286
DeveloperC286 force-pushed the claude/arity-checking-arguments-gu4ewf branch from f6017b4 to a226869 Compare September 6, 2026 13:22
@DeveloperC286
DeveloperC286 merged commit 44c0839 into main Sep 6, 2026
23 checks passed
@DeveloperC286
DeveloperC286 deleted the claude/arity-checking-arguments-gu4ewf branch September 6, 2026 13:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants