summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2023-08-08 07:10:03 -0700
committerKaz Kylheku <kaz@kylheku.com>2023-08-08 07:10:03 -0700
commitca9ecd3ded67f06c9cebe5b3fd4d6fb940342f44 (patch)
treed26f89be91f0fc5c22ae09739ec6b6671e502119
parent44453f30dd81ffa1e995662fd75a675b5b208406 (diff)
downloadtxr-ca9ecd3ded67f06c9cebe5b3fd4d6fb940342f44.tar.gz
txr-ca9ecd3ded67f06c9cebe5b3fd4d6fb940342f44.tar.bz2
txr-ca9ecd3ded67f06c9cebe5b3fd4d6fb940342f44.zip
doc: bit ore advice on unused variable diagnotics.
* txr.1: Mention that @nil can be used in pattern matching to suppress unused variable warnings.
-rw-r--r--txr.113
1 files changed, 12 insertions, 1 deletions
diff --git a/txr.1 b/txr.1
index 373f7547..70a115a2 100644
--- a/txr.1
+++ b/txr.1
@@ -88413,7 +88413,7 @@ named by uninterned symbols.
.brev
.IP 5.
-.BR "In pattern matching, put catch-all variable to use" :
+.BR "In destructuring and pattern matching, put catch-all variable to use" :
Examples:
@@ -88436,6 +88436,17 @@ Examples:
.brev
.IP 6.
+In pattern matching, use the
+.code @nil
+pattern:
+
+.verb
+ (match-case obj
+ ((@a @nil) (calculate-something a))
+ (@nil (transform obj)))
+.brev
+
+.IP 7.
.B "In macro parameter lists use t symbol" :
in macro-style parameter lists, any variable may be replaced by the
.code t