Share the const-keyword-lookup head predicates
The inliner and the type inferencer each recognized (:k m) and (get m :k) lookups with their own copy of the callee tests — the get-callee check was duplicated verbatim across both. Lift kw-callee?/get-callee? into jolt.passes.fold (alongside scalar-const?) and call them from both passes so the head recognition can't drift. Only the head predicates move. The deliberate differences stay: the inliner still accepts any scalar key in the get-form (its scalar-replacement targets can be string/number-keyed maps) while the inferencer requires keyword keys for struct field typing, and the inferencer keeps its two arms separate so each rebuilds args for its form. The backend's value-as-fn ifn-kind is left alone.
This commit is contained in:
parent
e9d56422bd
commit
a893e21111
5 changed files with 91 additions and 73 deletions
BIN
guestbook.sqlite3
Normal file
BIN
guestbook.sqlite3
Normal file
Binary file not shown.
Loading…
Add table
Add a link
Reference in a new issue