Skip to content

fix: Preserve symbol visibility - #2415

Merged
dcodeIO merged 1 commit into
masterfrom
patch/symbol-visibility
Aug 22, 2026
Merged

dcodeIO merged 1 commit into
masterfrom
patch/symbol-visibility

Conversation

@dcodeIO

@dcodeIO dcodeIO commented Aug 22, 2026

Copy link
Copy Markdown
Member

Preserves Edition 2024 local and export modifiers on reflection objects and during descriptor conversion.

Similar to #2401, but focused on preserving these modifiers without attempting to reimplement protoc's cross-file enforcement, which is less useful in protobuf.js's runtime schema loader respectively already performed by protoc when using the plugin.

@dcodeIO
dcodeIO merged commit ef47921 into master Aug 22, 2026
5 checks passed
@github-actions github-actions Bot mentioned this pull request Aug 21, 2026
morgan-coded added a commit to morgan-coded/protobuf.js that referenced this pull request Aug 27, 2026
Symbol visibility is parsed and preserved since protobufjs#2415, but nothing rejects a
reference to a local symbol from another file. Field#resolve now checks the
resolved type or enum and throws when it is local to a different file.

References without a known file name on either side (programmatic construction,
fromJSON, bundled common types) cannot be proven to cross files and are allowed.

Refs protobufjs#2400
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