wip(E4): partial source-pin + non-transitive flip [stdlib E4 attempt-1 WIP checkpoint]

Incomplete WIP from a worker killed at the 55-min wall (large blast radius:
core source-pin + ~8 example migrations + ~10 library module migrations).
Committed so the resumed session continues on a clean tree. May not build.
This commit is contained in:
agra
2026-06-08 11:12:08 +03:00
parent 4d539eeacd
commit 33a6f5c650
28 changed files with 202 additions and 58 deletions

View File

@@ -401,12 +401,17 @@ is rejected; qualify it with a namespaced import (`m :: #import …; m.fn()`).
A **namespaced** import only binds its alias: reach the module's members as
`m.name`. Bare-name visibility joins over flat (`#import "…"`) imports, never over
a namespaced alias. For **functions and constants** that join is non-transitive: a
flat import of a flat import is NOT bare-visible (when `A` imports `B` and `B`
imports `C`, `A` does not see `C`'s top-level names — qualify them). A bare
reference to a namespaced-only import's member — function, module constant, or
**type** — is not visible and is rejected (`type 'X' is not visible; #import the
module that declares it`); qualify it as `m.name`.
a namespaced alias. That join is **non-transitive for every bare member kind —
functions, constants, AND types alike**: a flat import of a flat import is NOT
bare-visible (when `A` imports `B` and `B` imports `C`, `A` does not see `C`'s
top-level names — including its types — so qualify them, or `#import "C"` directly
if you reference them). A bare reference to a namespaced-only import's member —
function, module constant, or **type** — is likewise not visible and is rejected
(`type 'X' is not visible; #import the module that declares it`); qualify it as
`m.name`. (A library's own *internal* type references still resolve: a generic
struct / pack fn / protocol body is instantiated in the module that defines it, so
e.g. `List(T).append`'s `alloc: Allocator` is visible there regardless of the call
site.)
### Implicit Context