You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
self-host P1: pin pub declarations in the t27core fixtures #7377
The self-host core specs/compiler/core/t27core.t27 already parses [pub] const|let|var|fn, but no fixture pins it, and no refusal pins the places where pub means nothing. This slice adds those as data only; the core gains no byte (it is at 65341 of 65536 bytes after #7374).
Probed on the Railway lab against t27c gen-c on master cd6708d:
shape
gen-c
core
pub let / pub const / pub var / pub fn, also with pub alone on its line
accepts; C bytes identical to the same file without pub
identical to gen-c
pub test name { ... }
accepts, drops pub
refuses, code 2
pub var x inside a fn body
accepts, drops pub
refuses, code 2
pub pub fn
refuses (exit 1)
refuses, code 2
pub use a::b;
refuses (exit 1)
refuses, code 1 (use is not a core word)
t27c gen (Zig) and t27c typecheck also accept pub test and a pub local and drop the word, so the drop is not lossy in any backend; the core takes the stricter reading and refuses both, since neither names something another module could import.
Deliverable, all under bootstrap/tests/fixtures/core_selfhost/:
accept/pub_shapes.t27 -- pub on let, const, var and fn, twice with pub on its own line; its test runs under -DT27_TEST_MAIN.
Check: cargo test --release -p t27c --test core_selfhost passes and the fixpoint core(t27core.t27) == gen-c(t27core.t27) holds (it does not change: no core edit).
Activity
specs_generate ledger: e1_pub_use and e2_pub_twice exist to be refuse…
self-host P1: pin pub declarations in the t27core fixtures (Closes #7377
fix(specs-generate): record #7436's three switch refuse fixtures (Closes