From 16837c56ee91655a0f8176491db2421fe7e6c586 Mon Sep 17 00:00:00 2001 From: Doug Coleman Date: Fri, 17 Jul 2015 01:54:35 -0700 Subject: [PATCH] macros: Fix docs to show macros output a quot. --- basis/macros/macros-docs.factor | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/basis/macros/macros-docs.factor b/basis/macros/macros-docs.factor index 91aa2fa3e5..8bc58fb2ef 100644 --- a/basis/macros/macros-docs.factor +++ b/basis/macros/macros-docs.factor @@ -3,7 +3,7 @@ stack-checker.transforms sequences combinators ; IN: macros HELP: MACRO: -{ $syntax "MACRO: word ( inputs... -- ) definition... ;" } +{ $syntax "MACRO: word ( inputs... -- quot ) definition... ;" } { $description "Defines a macro word. The definition must have stack effect " { $snippet "( inputs... -- quot )" } "." } { $notes "A call of a macro inside a word definition is replaced with the quotation expansion at compile-time. The following two conditions must hold:" @@ -17,7 +17,7 @@ HELP: MACRO: "A macro that calls a quotation but preserves any values it consumes off the stack:" { $code "USING: fry generalizations kernel macros stack-checker ;" - "MACRO: preserving ( quot -- )" + "MACRO: preserving ( quot -- quot' )" " [ inputs ] keep '[ _ ndup @ ] ;" } "Using this macro, we can define a variant of " { $link if } " which takes a predicate quotation instead of a boolean; any values consumed by the predicate quotation are restored immediately after:"