HEAD: a9e1f77. Milestone tags v3-step7 and v3-step7.1.
Suite 103/103 (all run via qbe → cc → run; 7 sessions,
4 session-output, 2 session-input, 4 trap-aborts, + rejects).
Build is warning-free (only the known-benign Coco TypeBlock LL(1)
advisory). Tree clean; git.txt untracked (ignored). No remote.
v3-step5.1…5.7 — FFI (EXTERNAL) + C shim; SysIO; HIGH/LEN;
Strings/TextIO; Math (libm) + WholeIO + input; Files;
module-qualified symbols + real qualified access; ADDRESS/ADR/
SIZE + Storage.v3-step6.1 (99) — CHR/ORD/VAL/ABS/INC/DEC.v3-step6.2 (100) — true 64-bit LONGINT/LONGCARD.v3-step7 (102) — value open-array formals; syslib gate;
bootstrap ABI analysis.v3-step7.1 (103) — self-hosted runtime/syslib/SysShim +
FileIO (V3-only).stdlib/: sysio, textio, strings, wholeio, math, files, storage.
runtime/syslib/: shim.c, SysShim, FileIO.
Full scalar + composite types, pointers/NEW/DISPOSE, records+WITH,
sets+IN, arrays (length-prefixed), procedures (value/VAR/array
params, recursion, nested + static-link display), separate
compilation (def/impl, FROM/IMPORT, qualified, opaque completion),
DEFINITION/IMPLEMENTATION, HIGH/LEN/SIZE/TSIZE/ADR/
NEW/DISPOSE/CHR/ORD/VAL/ABS/INC/DEC, 64-bit longs,
ADDRESS + Storage, FFI. 103 tests.
Goal was "port FileIO off gm2-only libs". Attempting it exposed a
fundamental bootstrap ABI conflict: gm2's ARRAY OF CHAR is a
NUL-terminated char* and its FFI is DEFINITION MODULE FOR "C"
EXPORT UNQUALIFIED; V3's is a length-prefixed descriptor with
PROCEDURE …; EXTERNAL;. One FileIO can't serve both.Resolution taken: bootstrap split (as Blaise does with FPC) —
stage 1 keeps the host FileIO; stage 2 links the self-hosted
runtime/syslib/FileIO (over SysShim/shim.c). Delivered and
tested (FioProg → 42).
0C/15C/177C/32C char-code literals → CHR(n);
&/~/<> → AND/NOT/#. (Compiler sources are otherwise
syslib-clean; only FileIO uses gm2-only libs, and it stays the
stage-1 host lib.)runtime/syslib).bootstrap/fixpoint.sh: Stage1 (gm2) → Stage2 (V3) →
Stage3 (V3), diff -r all .ssa byte-identical, suite green on
all three stages (rolling-bootstrap design per the Blaise map).Deferred everywhere: class lowering (vtable/THIS), procedure-type
variables, cross-class VAL/CAST, FLOAT/TRUNC, CAP,
long↔REAL conversions, strings escapes, WITH-field VAR actuals.
cd /home/eric/Projets/Projets-Modula2/MyWork/m2compiler-V3/compiler
./build.sh && ./run_tests.sh # expect 103/103, zero gm2 warnings
Recommended next: the compiler-source Redux sweep (step 8 prep).