Closed blackeyedpony closed 6 months ago
It's actually incorrect definition, it should be:
on init
define FOO := "apple", "banana", "pear", "kiwi"
message(FOO.SIZE)
end on
The way you wrote it it's looking for existence of variables named apple, banana etc, but they are not there so they cannot be messaged out.
Ah no, this should still work for variables, too. It was my wrong assumption that we should only count the string replacement tokens (they are wrapped in squigglies). Instead, we should count commas in the definition of literate define. That should fix it!
Try now!
according to Add #416 this should print "4", right ?
instead, the compiler throws:
apple has not been declared! (line 10) message(apple, banana, pear, kiwi.SIZE) \<main script>:6