fix four conditional operands sexc emitted without parentheses, and mark every Sex workaround with a TODO

A conditional as an operand loses its parentheses (sex#59): box-blur
allocated a quarter of its buffer, deep water got the shallow colour,
and verify's delta histogram wrote out of bounds into the height
classes. Plan.org quoted the corrupted count.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-08 21:01:59 +03:00
parent 39b0e74f2b
commit c14c154303
22 changed files with 156 additions and 5 deletions

View File

@@ -16,10 +16,14 @@ all: $(B)/vsmv $(B)/vs-map-viewer
# sexc writes no dependency files, and an import pastes the imported
# module's public forms into the importer, so any Sex source may change
# any Sex object.
# TODO sex#40: depend on what each unit imports once sexc writes
# dependency files.
SEX_SRC := $(wildcard src/*.sex)
# Statement-level #line directives can land inside a ?: and break the
# C (see Sex-field-notes.org), so they are kept to toplevel forms.
# TODO sex#54: drop --line-directives=toplevel once #line no longer
# lands inside a ?:.
$(B)/%.o: src/%.sex $(SEX_SRC) | $(B)
$(SEXC) --line-directives=toplevel $< -c -o $@ -- $(CFLAGS) $(SEX_CFLAGS) $(CPPFLAGS)