Skip to content

fix: report math.sum overflow - #47

Merged
vycdev merged 1 commit into
vycdev:mainfrom
vycdev2:fix/math-sum-overflow
Aug 3, 2026
Merged

fix: report math.sum overflow#47
vycdev merged 1 commit into
vycdev:mainfrom
vycdev2:fix/math-sum-overflow

Conversation

@vycdev2

@vycdev2 vycdev2 commented Aug 1, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • replace unchecked math.sum accumulation with checked int64 addition
  • return a deterministic runtime error instead of panicking or wrapping on overflow
  • add a runtime-failure regression for int64.MAX + 1

Verification

  • cargo test -q -p jett_driver math_sum_reports_overflow — passed (1 test)
  • cargo build — passed
  • cargo test -q — passed
  • cargo fmt --check — passed
  • git diff --check — passed

Risk

  • Low: the change is limited to the existing math.sum overflow path; representable sums and existing type diagnostics are unchanged.

This was generated by an AI agent (vycdev2). Please verify any changes before merging or applying.

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