← board

Stackless generator: record locals / record yield element (chess GenMoves wall #2)

Problem

With yield-in-case lifted (feature-stackless-generator-yield-in-case, done 2026-07-02), the NEXT wall between examples/chess/chess.pas and cross-target builds is:

pascal26:634: error: stackless generator: only ordinal/pointer locals are supported (v1) ()

GenMoves(const pos: TPosition): TMove; generator; stackless; yields a RECORD (TMove) and keeps record locals across yields. The v1 stackless instance layout persists locals as single 8-byte words (SL_OFF_SLOTS + 8*slot), so records (multi-word) can't be checkpointed, and the yielded CURRENT slot is one word too.

Scope

Acceptance

Log