Another missing endef silently ignored
colincross opened this issue · comments
Colin Cross commented
define test1
# Typo below, endif instead of endef
endif
define test2
endef
foo:
echo FAIL
$ make -f test.mk
test.mk:1: *** missing `endef', unterminated `define'. Stop.
$ ckati -f test.mk
echo FAIL
FAIL
This is related to kati not supporting nested defines:
define outer
define inner
PASS
endef
endef
A := $(inner)
$(eval $(outer))
foo:
echo $(A)
echo $(inner)
$ make -f test.mk
echo
echo PASS
PASS
$ ckati -f test.mk
test.mk:5: *** missing separator.
Properly supporting nested defines doesn't seem important, but parsing them correctly does.