-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Description
I would specify the quasiquote as follows:
For each item in a list:
- append the item to a news list unless:
-- It is an unquote list. Evaluate the list item first before appending it
-- It is a splice-unquote list. Instead of appending the list, append the items in the list in sequence.
The evaluation is not ambiguous, assuming quasiquote is not supposed to change the environment.
If the items do that as a side effect, I'm totally lost, especially if they are calculated from behind.
This is trivial to implement to the manipulation compared to with cons and concat. What am I missing here?
List and vectors in my implementation are consequitive, not linked. So each times rest is called I'm obliged to allocate a fresh area and copy the whole bunch. If the specification in terms of the classic cons has to do with ease of implementation?