Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Clean up syntax for list to list assignments
list !* ANY remove all attributes in the list list := list2 delete list, copy list2, and assign the copy to list list += list2 copy list2, and append the copy to list list := `foo` read attrs from program, and assign to list list += `foo` read attrs from program, and append to list
- Loading branch information
Showing
2 changed files
with
41 additions
and
14 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
# | ||
# PRE: update | ||
# | ||
# It's an error to update lists that don't exist. | ||
# | ||
update { | ||
request := reply | ||
config += request | ||
reply !* ANY | ||
} | ||
|
||
update { | ||
reply += `/path/to/foo bar baz` | ||
} | ||
|
||
|
||
update { | ||
request := nope # ERROR | ||
} |