Skip to content

Vendor the v0.15.16 core libraries - #143

Open
biuld wants to merge 7 commits into
masterfrom
stdlib/vendor-core-libraries
Open

biuld wants to merge 7 commits into
masterfrom
stdlib/vendor-core-libraries

Conversation

@biuld

@biuld biuld commented Oct 4, 2026

Copy link
Copy Markdown
Owner

Summary

  • Vendors the PureScript v0.15.16 core libraries and loads them as the trusted standard library.
  • Adds compile diagnosis (manifest, trace, and replay) for iterating on the failures that remain.
  • Treats variables bound by a rank-n field quantifier as non-free, so a closed dictionary record keeps its canonical layout.

This is still open. discard and map over Effect still trap in Wasmtime with a cast failure; compile acceptance is not the acceptance check for those cases.

Test plan

  • cargo test -p psrs-backend --lib bound_rank_n_record_fields_do_not_make_dictionary_layout_dependent
  • PSRS_REQUIRE_WASMTIME=1 cargo test -p psrs-driver --lib discard_defined_from_bind_sequences_effects
  • PSRS_REQUIRE_WASMTIME=1 cargo test -p psrs-driver --lib mapping_an_effect_does_not_run_it_until_the_action_runs

biuld added 7 commits October 4, 2026 18:43
Prelude keeps the psrs:effect bindings and re-exports the official class
hierarchy. Data.Show and Data.Tuple stay the implementations this compiler
already lowers. Value foreign imports become intrinsics or diverging stubs.

The parser accepts an `as@` named pattern and a `where` block on a pattern
binding. A backticked local binds tighter than a symbolic operator. A module
re-export keeps the imported data constructors, `Partial` is in scope without
an import, and `T()` exports a type with none of its constructors. `-` and
`/` are the library operators over `intSub` and `intQuot`.

The trusted set parses. Modules that construct an algebraic `Tuple`, or that
call FFI this target does not implement, still fail resolve. No scoreboard
number moves.

Refs #94
A rank-n dictionary field quantifies its own variables, so those variables
do not make the record's layout depend on a free type variable. Parameter
shapes then use the same scalar layout as other closed records instead of
the erased aggregate special case.
PSRS_DUMP_CC and PSRS_DUMP_WAT write the calling-convention and text
forms beside a focused runtime test without changing the compiled artifact.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant