forked from rebolsource/r3
-
Notifications
You must be signed in to change notification settings - Fork 27
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Simplify and enhance SHOVE (->), make #defer/#shove TWEAKs
The enfix covenant meant that SHOVE's implementation could simplify quite a bit, since it can presume one unit of evaluation or quoting on the part of the thing it is shoving into. This takes advantage of that simplification and implements a few more points: * SHOVE has a unique higher priority tweak, allowing it to resolve the quoting contention first encountered with `help/doc default`, where a right quoting operator obscured behind a path was losing to a left quoting operator. Instead, a path that does not wind up as a right quoting operator will yield an error message instructing the user to use SHOVE, e.g. `obj/value -> left-lit` * Rather than having SET-WORD! and SET-PATH! getting shoved to the right for an evaluative leftward slot of an action be an error, this gives it the meaning of fetching the value currently in that set word or set path...feeding it in as the first argument...and then writing back into the word or path. If the path contains groups this is done only once. The implementation is not currently optimized in ways it could be. It generates a full specialization rather than run as an APPLY, for simplicity...and also uses the API to process SET-PATH!s and avoid any double-evaluations of groups. But this took a step toward getting the more complicated manipulations out of the evaluator itself, as they are no longer needed with the new promises about enfix.
- Loading branch information
1 parent
2730325
commit f9d4985
Showing
22 changed files
with
405 additions
and
286 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.