Skip to content

Phase 4: reach 100% on the L4 type and L5 class gates #77

Closed
4 of 4 issues completed
Closed

Description

@biuld

Why this phase

Phase 1 makes L4/L5 measurable; Phases 2 and 3 unblock the corpus. This phase turns "measurable" into "passing". The first sub-issue is nearly free — it is a mapping table — and it is worth doing first because it converts 153 corpus cases from invisible to tracked.

Baseline

M4 (61 mapped cases) and M5 (92 mapped cases) are both unmeasured. The corpus splits as:

M4 code Cases M5 code Cases
TypesDoNotUnify 41 NoInstanceFound 53
HoleInferredType 10 OverlappingInstances 8
EscapedSkolem 2 InvalidInstanceHead 7
CannotApplyExpressionOfTypeOnType 2 OrphanInstance 7
ExpectedType 2 InvalidNewtypeInstance 6
InfiniteType 2 ClassInstanceArityMismatch 4
AmbiguousTypeVariables 1 CycleInTypeClassDeclaration 2
IntOutOfRange 1 MissingClassMember 2
PossiblyInfiniteInstance, DuplicateTypeClass, DuplicateInstance 1 each

Sub-issues

Tracked as children of this epic.

Gate

L4 and L5 reach 100% agreement on their mapped codes, with the scoreboard from Phase 1 reporting the per-code numbers.

References

  • docs/design/D-04-suite-roadmap.md — M4, M5, FE-08..FE-16
  • crates/psrs-typecheck/src/typecheck/error.rs — the kinds to map
  • docs/design/frontend/type-system/ — the normative type-system design
  • docs/implementation/frontend/roles-and-coercions.md, docs/implementation/frontend/rank-n.md

Validation

cargo fmt --all --check
cargo test --workspace
cargo clippy --workspace --all-targets -- -D warnings
PSRS_ORACLE=annotations cargo test -p psrs-driver --test suite -- --ignored --nocapture

Activity

  1. biuld commented on Oct 22, 2026

    @biuld
    OwnerAuthor

    The mapped Phase 4 gate is complete: L3 50/50, L4 65/65, L5 101/101, with 166 measured L4/L5 cases. This does not assert full frontend or runtime completion.

    Verified by PR #164 (41a16e2): formatting, default Clippy, full workspace (2331 passed, zero failed), five separately executed frontend boards, all 22 official purs differential tests, and the complete serial runtime board (297/340; 25 FFI exclusions; every agreeing exit zero). Required Wasmtime CI execution check 119961920075 completed successfully. The three losses versus the older board reproduce on the unmodified starting HEAD; BigFunction remains an explicit incomplete compiler verdict.

    Evidence: Phase 4 acceptance review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions