summaryrefslogtreecommitdiff
path: root/doc/ref/api-macros.texi
diff options
context:
space:
mode:
authorAndy Wingo <wingo@igalia.com>2013-03-13 11:41:01 +0100
committerAndy Wingo <wingo@pobox.com>2013-03-13 11:43:35 +0100
commit8ae26afefee947c71314733c419519fb616bf36d (patch)
tree9a484e63f8c78e8f1870dd28bfdd66b7f97d8d1b /doc/ref/api-macros.texi
parent9b977c836bf147d386944c401113aba32776fa68 (diff)
downloadguile-8ae26afefee947c71314733c419519fb616bf36d.tar.gz
add #:resolve-syntax-parameters? kwarg to syntax-local-binding
* doc/ref/api-macros.texi (Syntax Transformer Helpers): Document. * module/ice-9/psyntax.scm (syntax-local-binding): Add #:resolve-syntax-parameters? kwarg. Fixes bug 10991. * module/ice-9/psyntax-pp.scm: Regenerate. * test-suite/tests/syncase.test ("syntax-local-binding"): Add test.
Diffstat (limited to 'doc/ref/api-macros.texi')
-rw-r--r--doc/ref/api-macros.texi10
1 files changed, 8 insertions, 2 deletions
diff --git a/doc/ref/api-macros.texi b/doc/ref/api-macros.texi
index 347d02589..b08c1035a 100644
--- a/doc/ref/api-macros.texi
+++ b/doc/ref/api-macros.texi
@@ -1,6 +1,6 @@
@c -*-texinfo-*-
@c This is part of the GNU Guile Reference Manual.
-@c Copyright (C) 1996, 1997, 2000, 2001, 2002, 2003, 2004, 2009, 2010, 2011, 2012
+@c Copyright (C) 1996, 1997, 2000, 2001, 2002, 2003, 2004, 2009, 2010, 2011, 2012, 2013
@c Free Software Foundation, Inc.
@c See the file guile.texi for copying conditions.
@@ -725,7 +725,7 @@ Return the name of the module whose source contains the identifier
@var{id}.
@end deffn
-@deffn {Scheme Procedure} syntax-local-binding id
+@deffn {Scheme Procedure} syntax-local-binding id [#:resolve-syntax-parameters?=#t]
Resolve the identifer @var{id}, a syntax object, within the current
lexical environment, and return two values, the binding type and a
binding value. The binding type is a symbol, which may be one of the
@@ -738,6 +738,12 @@ of @code{eq?}) identifying this binding.
@item macro
A syntax transformer, either local or global. The value is the
transformer procedure.
+@item syntax-parameter
+A syntax parameter (@pxref{Syntax Parameters}). By default,
+@code{syntax-local-binding} will resolve syntax parameters, so that this
+value will not be returned. Pass @code{#:resolve-syntax-parameters? #f}
+to indicate that you are interested in syntax parameters. The value is
+the default transformer procedure, as in @code{macro}.
@item pattern-variable
A pattern variable, bound via syntax-case. The value is an opaque
object, internal to the expander.