So right now, there are three metaprogramming elements:
poems build into kernels
stanzas allow for users to mix verses
verses are the minimal building block, similar to functions
But it is possible to move the functionality from stanzas to verses, by enabling __split_verse() as a feature of verses. Moreover, it's possible to allow for multiple splits. This can be done by searching for the verse name when parsing the poem and finding the number of splits (num_splits or something) and then finding all subsequent {} pairs after the config.
I need to think about whether this is actually useful ro not. I do kinda like having separation of concerns with stanzas and verses. As it is now, stanzas are more or less always used as generators in such a way that users shouldn't really be touching them too much. It's nice to signal to the users that "this thing is a bit tricky to use correctly, so tread with caution."
So right now, there are three metaprogramming elements:
poemsbuild into kernelsstanzasallow for users to mix versesversesare the minimal building block, similar to functionsBut it is possible to move the functionality from
stanzastoverses, by enabling__split_verse()as a feature ofverses. Moreover, it's possible to allow for multiple splits. This can be done by searching for the verse name when parsing the poem and finding the number of splits (num_splitsor something) and then finding all subsequent{}pairs after the config.I need to think about whether this is actually useful ro not. I do kinda like having separation of concerns with stanzas and verses. As it is now,
stanzasare more or less always used as generators in such a way that users shouldn't really be touching them too much. It's nice to signal to the users that "this thing is a bit tricky to use correctly, so tread with caution."