summaryrefslogtreecommitdiffstats
path: root/txr.1
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2015-10-06 21:03:52 -0700
committerKaz Kylheku <kaz@kylheku.com>2015-10-06 21:03:52 -0700
commit829f02b346d4060e64ec5847cbd0f066edd4a144 (patch)
treee49bb65e98537b833e1d49a88008b30b175a96c2 /txr.1
parent4adbf9319259d94604c9f5b5d27c3b3e3e0118f0 (diff)
downloadtxr-829f02b346d4060e64ec5847cbd0f066edd4a144.tar.gz
txr-829f02b346d4060e64ec5847cbd0f066edd4a144.tar.bz2
txr-829f02b346d4060e64ec5847cbd0f066edd4a144.zip
New function: clear-struct.
* struct.c (clear_struct): New function. (struct_init): Register clear-struct intrinsic. * struct.h (struct_init): Declared. * txr.1: documented clear-struct.
Diffstat (limited to 'txr.1')
-rw-r--r--txr.118
1 files changed, 18 insertions, 0 deletions
diff --git a/txr.1 b/txr.1
index 092e1469..ba079edc 100644
--- a/txr.1
+++ b/txr.1
@@ -18727,6 +18727,24 @@ function returns the structure type object which
defines the type of the structure object
.metn struct-obj .
+.coNP Function @ clear-struct
+.synb
+.mets (clear-struct < struct-obj <> [ value ])
+.syne
+.desc
+The
+.code clear-struct
+replaces all instance slots of
+.meta struct-obj
+with
+.metn value ,
+which defaults to
+.code nil
+if omitted.
+
+Note that finalizers are not executed prior to replacing
+the slot values.
+
.coNP Function @ method
.synb
.mets (method < struct-obj << slot-name )