mojo_client/bin/scripts/append.def
False.Genesis 06942daea6 * fixed a little bug(?) in the variable importer
* implemented SCP database functionality (.scp files). (sounds familiar? :P )
* new DefScript command: "loadscp,name filename"
* added .def file: append.def. (wrapper to concat strings)
** -> note that the scp db has no real use right now, just some program internal stuff which will come tomorrow. soon i'll have a go at DefScript return values, useable e.g. to get data from the dbs.
2007-03-04 00:18:58 +00:00

15 lines
461 B
Modula-2

#permission=255
// usage: append text to a string.
// args:
// @def: text to append
// @0: variable to which the text should be appended
// get the var name if the original variable
SET,v #${@caller}::${@0}
// if it has not been set before, init it now
DEFAULT,${v}
// append to the original var. inner ${..} gets the var name, outer ${..} get the value of the var name we just got.
SET,${v} ${${v}}${@def}
// remove the name placeholder
UNSET v