5 Commits

Author SHA1 Message Date
f83ca7de6f Two rules the checker was missing
A shift by the operand's own width or more is poison in LLVM, not a wrong
number: (<< 1 32) at -O2 compiled to a bare retq. A literal count out of range
is now rejected in check.ml, and emit.ml masks a computed one to width - 1,
which is what the hardware does and which LLVM folds away for a constant.

There is one top-level namespace, but the environment's tables are per-kind, so
only a function was ever checked for a duplicate. (defn item ...) beside
(defvar item ...) type checked and then died in LLVM as a redefinition of
'@flan.item'; two colliding type declarations were not caught anywhere. One
pass over Ast.declared_name now runs before every other collection pass. That
function lives in ast.ml because Load needs the same set - the names an import
renames - and two copies would drift.
2026-09-10 21:05:08 +07:00
60a1928ee3 Raylib runs, Heckin yeah 2026-09-10 18:55:55 +07:00
542e5d5fbc Making progress 2026-09-10 18:07:50 +07:00
c476d05f7d i dunno lol 2026-09-10 17:49:24 +07:00
6d86d09a84 Type checking and stuff 2026-09-10 17:27:53 +07:00