diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2017-03-17 06:05:29 -0700 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2017-03-17 06:05:29 -0700 |
commit | e318f2a001b72f279c9f8637e5f4e7592e29eb37 (patch) | |
tree | aded87e7acc72dfde6ab2a641a49616d5b07fc06 /txr.1 | |
parent | c609898ed0bdb212bd5b53758cd22f617d9760df (diff) | |
download | txr-e318f2a001b72f279c9f8637e5f4e7592e29eb37.tar.gz txr-e318f2a001b72f279c9f8637e5f4e7592e29eb37.tar.bz2 txr-e318f2a001b72f279c9f8637e5f4e7592e29eb37.zip |
Document opt function.
* txr.1: Add missing description of the opt convenience
function for constructing opt-desc structures.
Diffstat (limited to 'txr.1')
-rw-r--r-- | txr.1 | 38 |
1 files changed, 38 insertions, 0 deletions
@@ -45845,6 +45845,44 @@ convenience function is provided for constructing .code opt-desc objects. +.coNP Function @ opt +.synb +.mets (opt < short < long >> [ type <> [ helptext ]]) +.syne +.desc +The +.code opt +function provides a slightly condensed syntax for constructing +an object of type +.codn opt-desc . + +The required arguments +.meta short +and +.meta long +are strings, corresponding to +.code opt-desc +slots of the same name. + +The optional parameter +.meta type +corresponds to the same-named slot and defaults to +.codn :bool . + +The optional parameter +.meta helptext +corresponds to the same-named slot, and defaults to +.code nil +(no help text provided for the option). + +The +.code opt +function follows this equivalence: + +.cblk + (opt a b c d) <--> (new opt-desc short a long b type c helptext d) +.cble + .coNP Structure @ opts .synb .mets (defstruct opts nil |