Skip to content

fix: use correct struct type for stringmap .size dispatch#175

Merged
cs01 merged 2 commits intomainfrom
fix/stringmap-size-dispatch
Mar 10, 2026
Merged

fix: use correct struct type for stringmap .size dispatch#175
cs01 merged 2 commits intomainfrom
fix/stringmap-size-dispatch

Conversation

@cs01
Copy link
Copy Markdown
Owner

@cs01 cs01 commented Mar 10, 2026

Summary

  • .size on Map<string, *> variables now dispatches to generateStringMapSize (uses %StringMap*) instead of generateMapSize (uses %Map*). Same layout so it worked by luck, but technically wrong LLVM IR type.
  • Same fix for this.field.size on Map<string, *> class fields
  • Added generateStringMapSize to IStringMapGenerator interface
  • Added stringMapGen to MemberAccessGeneratorContext for property handler access
  • Removed no-op try { ... } catch (e) { throw e; } in response method dispatch

Test plan

  • All 448 tests pass
  • Self-hosting passes (quick mode)
  • Existing map-string-keys.ts test covers .size on StringMap

🤖 Generated with Claude Code

cs01 and others added 2 commits March 9, 2026 21:03
…/catch

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@cs01 cs01 merged commit f01e81a into main Mar 10, 2026
12 checks passed
@cs01 cs01 deleted the fix/stringmap-size-dispatch branch March 12, 2026 05:35
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.

1 participant