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
commitc0a71b938980a568155f56c7e72dd86c842e48c6 (patch)
treed26f89be91f0fc5c22ae09739ec6b6671e502119
parentb7764b7b4baa7454f71dc2a2bfedb2753425bdfe (diff)
downloadtxr-c0a71b938980a568155f56c7e72dd86c842e48c6.tar.gz
txr-c0a71b938980a568155f56c7e72dd86c842e48c6.tar.bz2
txr-c0a71b938980a568155f56c7e72dd86c842e48c6.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