docs: drop leading // from heph.core.pkg() example#40
Merged
Conversation
A package path is the workspace-relative directory after the //, as defined in the Addresses reference (//package:name). The // marks an address, not a package, so heph.core.pkg() returns "tools/build", not "//tools/build". Fix the example in both the docs page and its reference twin. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01H4ogQLEQwBri6r6y7VKv2M
⚡ Cloudflare Pages preview
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
heph.core.pkg()is documented as returning the current package path, but the example value included a leading//:website/docs/plugins/buildfile.md→"//tools/build"plugins/heph-expert/skills/heph/references/authoring.md→//tools/buildWhy
The Addresses reference (
website/docs/reference/addresses.md) defines the terms precisely://(root package is the empty string, written//:name).//-prefixed//package:namestring.So the
//marks an address, not a package path. A package path istools/build(or""for root), never//tools/build. The example contradicted the repo's own definition.This updates both the docs page and its reference twin together, per the reference-drift rule in
CLAUDE.md.Note
This fix is based on the repo's own internal definitions of "package" vs "address" — I wasn't able to reach the heph engine source from this environment to confirm the builtin's exact runtime string. If
pkg()is actually intended to return the//-prefixed form, the wording "current package path" would be the thing to fix instead.🤖 Generated with Claude Code
https://claude.ai/code/session_01H4ogQLEQwBri6r6y7VKv2M
Generated by Claude Code