From cf5fbe748a05001e840d3efcdba15e8d56369ccb Mon Sep 17 00:00:00 2001 From: Kaz Kylheku Date: Wed, 17 Feb 2021 07:51:27 -0800 Subject: doc: improve quote operator. * txr.1: Improved description of quote operator. --- txr.1 | 36 ++++++++++++++++++++++++++++-------- 1 file changed, 28 insertions(+), 8 deletions(-) diff --git a/txr.1 b/txr.1 index 7ede2f66..84c25462 100644 --- a/txr.1 +++ b/txr.1 @@ -13671,19 +13671,39 @@ and instead returns .meta form itself as an object. For example, if .meta form -is a symbol, then -.meta form -is not evaluated to the symbol's value; rather -the symbol itself is returned. +is a symbol +.metn sym , +then the value of +.mono +.meti (quote << sym ) +.onom +is +.meta sym +itself. Without +.codn quote , +.meta sym +would evaluate to the value held by the variable which is named +.metn sym , +or else throw an error if there is no such variable. +The +.code quote +operator never raises an error, if it is given exactly one argument, +as required. -Note: the quote syntax +The notation +.mono +.meti >> ' obj +.onom +is translated to the object .mono -.meti >> ' form +.meti (quote << obj ) .onom -is translated to +providing a shorthand for quoting. Likewise, when an object of the form .mono -.meti (quote << form ). +.meti (quote << obj ) .onom +is printed, it appears as +.codn 'obj . .TP* Example: -- cgit v1.2.3