Skip to content

fix(dsl): support class pointer arguments#50

Merged
nazarhussain merged 1 commit into
mainfrom
fix/dsl-class-pointer-args
Jul 14, 2026
Merged

fix(dsl): support class pointer arguments#50
nazarhussain merged 1 commit into
mainfrom
fix/dsl-class-pointer-args

Conversation

@GrapeBaBa

@GrapeBaBa GrapeBaBa commented Jul 14, 2026

Copy link
Copy Markdown
Contributor

Summary

  • make the class-pointer branch in convertArg comptime so *Class parameters reach unwrapChecked
  • add JS DSL integration coverage for mutating a borrowed class pointer
  • verify that passing a different wrapped class throws a TypeError before native access

Motivation

convertArg documents support for both class values and class pointers, but the pointer branch used a runtime if. Zig still analyzed the fallback @compileError, so exported functions accepting *Class could not compile. Consumers working around this with raw napi_unwrap can bypass zapi type-tag validation.

@nazarhussain
nazarhussain merged commit 9dd2111 into main Jul 14, 2026
6 checks passed
@nazarhussain
nazarhussain deleted the fix/dsl-class-pointer-args branch July 14, 2026 12:22
spiral-ladder pushed a commit to ChainSafe/lodestar-z that referenced this pull request Jul 19, 2026
## Summary

- route every BLST class extraction through zapi typed conversion so
N-API type tags are checked before `napi_unwrap`
- pin zapi to the merge commit of
[ChainSafe/zapi#50](ChainSafe/zapi#50) until the
pointer-argument fix is released
- add regression coverage for wrong-class values across
signature/public-key aggregation and randomized verification paths

## Motivation

Raw `Env.unwrap` accepts any wrapped N-API object. Passing a `SecretKey`
where a `PublicKey` or `Signature` is expected can therefore reinterpret
a smaller native allocation as a larger structure and read beyond its
bounds.
wemeetagain pushed a commit that referenced this pull request Jul 20, 2026
## Summary

Add an explicit `changelog-sections` config to
`release-please-config.json` so generated release notes group commits
into named sections.

Visible sections: Features, Bug Fixes, Performance Improvements, Code
Refactoring, Dependencies, Reverts, Miscellaneous Chores, Documentation.

Hidden types (`build`, `ci`, `test`, `style`) are marked `hidden: true`
so they don't clutter the changelog.

## Motivation

With the default release-please changelog config, only `feat` and `fix`
map to visible sections; other conventional-commit types (including
`refactor`) are hidden. As a result, #53 (`refactor(js): unify env
lifecycle refcounting`) was merged but did **not** appear in the open
release PR #51, whose changelog only shows the `Bug Fixes` entry for
#50.

Adding `refactor` → "Code Refactoring" (and the other types above) as
visible sections ensures such changes are reflected in future release
notes.

## Test plan

- [x] JSON validated (`python3 -m json.tool`)
- Config takes effect on the next release-please run

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.

3 participants