fix(0114): gate alias-qualified calls to one-level carry, pin to target
The lowerCall namespace branch routed alias.fn() through the global qualified registration (first-wins) at any import depth, and through the global last-wins bare map for comptime/generic members. Plain-identifier alias roots now resolve via the carry-aware namespaceAliasVerdict: - visible alias (own edge or ONE flat hop): the member dispatches the TARGET module's own fn (namespaceFnMember + fd-keyed bareAuthorFuncId), so two modules' same-named aliases each call their own target. - two direct flat imports carrying the alias to distinct targets: loud ambiguity diagnostic. - alias only reachable beyond one hop: "namespace 'X' is not visible". - foreign / builtin / #compiler members keep the literal-symbol path. Regressions: examples 0832 (two-hop), 0833 (carried collision), 0834 (own-target pin / first-wins repair).
This commit is contained in:
@@ -0,0 +1,2 @@
|
||||
t :: #import "x.sx";
|
||||
use_a :: () -> s64 { t.fx() }
|
||||
@@ -0,0 +1,2 @@
|
||||
t :: #import "y.sx";
|
||||
use_b :: () -> s64 { t.fy() }
|
||||
@@ -0,0 +1 @@
|
||||
fx :: () -> s64 { 1 }
|
||||
@@ -0,0 +1 @@
|
||||
fy :: () -> s64 { 2 }
|
||||
Reference in New Issue
Block a user