docs: document export_name attribute - #1296
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 5e06f3e0e5
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| msgstr "" | ||
|
|
||
| #: ../../language/attributes/export_name.md:15 | ||
| #, fuzzy |
There was a problem hiding this comment.
Clear fuzzy flags from translated export text
In the zh_CN build, this newly translated paragraph will still appear in English because gettext excludes a msgstr marked fuzzy; the same flag remains on the corresponding new export paragraphs in attributes/export_name.po, error_codes/E4219.po, ffi.po, and toolchain/moon/package.po. Clear these flags after verifying the translations so the Chinese text is actually rendered.
AGENTS.md reference: AGENTS.md:L31-L35
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 54e587b416
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| "反対に `#owned` は、引数が FFI 関数側で保持され、後で `decref` を手動で実行する必要がある意味論です。利用例の 1 " | ||
| "つは、クロージャが **owned** になるコールバックの登録です。" | ||
|
|
||
| #~ msgid "" |
There was a problem hiding this comment.
Remove stale duplicate messages from Japanese catalogs
When the Japanese catalogs are compiled with GNU gettext, this obsolete entry has exactly the same msgid as the active entry at line 557, so compilation aborts with a duplicate-message error; the same newly added defect occurs in toolchain/moon/package.po at lines 208 and 2542. Remove both stale obsolete blocks, or deduplicate them through the prescribed i18n synchronization workflow, so standard PO tooling can consume these catalogs.
AGENTS.md reference: AGENTS.md:L24-L27
Useful? React with 👍 / 👎.
Summary
#export_nameto the attributes reference with its placement and naming constraints#export_namefor new exports, while retainingexportsfor backend-specific export sets or namesv128.loadfallback recursion as a known compiler issue rather than a Windows/SSE2 incompatibilityWhy
#export_namewas missing from the attributes overview, and the existing FFI text presented it alongside backend link configuration without a clear recommendation. The downstream-package note also did not explain that declarations in a dependency affect the dependency's own artifact but do not propagate into another package's artifact.The compiler currently applies the same C-compatible export-name check to every backend even though WebAssembly export names are UTF-8 strings. Separately, the Windows exclusion for the
v128leexample works around recursive C-backend fallback code; presenting either behavior as an inherent platform restriction would be misleading.Correctness and scope
The documented scope matches package-level linking: the package producing the artifact defines its exports, while dependency declarations remain local to dependency artifacts. The change keeps backend-specific configuration available when export sets or names must differ by backend, and limits the workarounds to the affected compiler behavior.