This file is indexed.

/usr/share/doc/racket/reference/syntax-util.html is in racket-doc 6.1-4.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"/><title>12.11&nbsp;Syntax Utilities</title><link rel="stylesheet" type="text/css" href="../scribble.css" title="default"/><link rel="stylesheet" type="text/css" href="extras.css" title="default"/><link rel="stylesheet" type="text/css" href="../racket.css" title="default"/><link rel="stylesheet" type="text/css" href="../manual-style.css" title="default"/><link rel="stylesheet" type="text/css" href="../manual-racket.css" title="default"/><link rel="stylesheet" type="text/css" href="../manual-racket.css" title="default"/><link rel="stylesheet" type="text/css" href="../doc-site.css" title="default"/><script type="text/javascript" src="../scribble-common.js"></script><script type="text/javascript" src="../manual-racket.js"></script><script type="text/javascript" src="../manual-racket.js"></script><script type="text/javascript" src="../doc-site.js"></script><script type="text/javascript" src="../local-redirect/local-redirect.js"></script><script type="text/javascript" src="../local-redirect/local-user-redirect.js"></script><!--[if IE 6]><style type="text/css">.SIEHidden { overflow: hidden; }</style><![endif]--></head><body id="doc-racket-lang-org"><div class="tocset"><div class="tocview"><div class="tocviewlist tocviewlisttopspace"><div class="tocviewtitle"><table cellspacing="0" cellpadding="0"><tr><td style="width: 1em;"><a href="javascript:void(0);" title="Expand/Collapse" class="tocviewtoggle" onclick="TocviewToggle(this,&quot;tocview_0&quot;);">&#9658;</a></td><td></td><td><a href="index.html" class="tocviewlink" data-pltdoc="x"><span style="font-weight: bold">The Racket Reference</span></a></td></tr></table></div><div class="tocviewsublisttop" style="display: none;" id="tocview_0"><table cellspacing="0" cellpadding="0"><tr><td align="right">1&nbsp;</td><td><a href="model.html" class="tocviewlink" data-pltdoc="x">Language Model</a></td></tr><tr><td align="right">2&nbsp;</td><td><a href="notation.html" class="tocviewlink" data-pltdoc="x">Notation for Documentation</a></td></tr><tr><td align="right">3&nbsp;</td><td><a href="syntax.html" class="tocviewlink" data-pltdoc="x">Syntactic Forms</a></td></tr><tr><td align="right">4&nbsp;</td><td><a href="data.html" class="tocviewlink" data-pltdoc="x">Datatypes</a></td></tr><tr><td align="right">5&nbsp;</td><td><a href="structures.html" class="tocviewlink" data-pltdoc="x">Structures</a></td></tr><tr><td align="right">6&nbsp;</td><td><a href="mzlib_class.html" class="tocviewlink" data-pltdoc="x">Classes and Objects</a></td></tr><tr><td align="right">7&nbsp;</td><td><a href="mzlib_unit.html" class="tocviewlink" data-pltdoc="x">Units</a></td></tr><tr><td align="right">8&nbsp;</td><td><a href="contracts.html" class="tocviewlink" data-pltdoc="x">Contracts</a></td></tr><tr><td align="right">9&nbsp;</td><td><a href="match.html" class="tocviewlink" data-pltdoc="x">Pattern Matching</a></td></tr><tr><td align="right">10&nbsp;</td><td><a href="control.html" class="tocviewlink" data-pltdoc="x">Control Flow</a></td></tr><tr><td align="right">11&nbsp;</td><td><a href="concurrency.html" class="tocviewlink" data-pltdoc="x">Concurrency and Parallelism</a></td></tr><tr><td align="right">12&nbsp;</td><td><a href="Macros.html" class="tocviewselflink" data-pltdoc="x">Macros</a></td></tr><tr><td align="right">13&nbsp;</td><td><a href="input-and-output.html" class="tocviewlink" data-pltdoc="x">Input and Output</a></td></tr><tr><td align="right">14&nbsp;</td><td><a href="security.html" class="tocviewlink" data-pltdoc="x">Reflection and Security</a></td></tr><tr><td align="right">15&nbsp;</td><td><a href="os.html" class="tocviewlink" data-pltdoc="x">Operating System</a></td></tr><tr><td align="right">16&nbsp;</td><td><a href="memory.html" class="tocviewlink" data-pltdoc="x">Memory Management</a></td></tr><tr><td align="right">17&nbsp;</td><td><a href="unsafe.html" class="tocviewlink" data-pltdoc="x">Unsafe Operations</a></td></tr><tr><td align="right">18&nbsp;</td><td><a href="running.html" class="tocviewlink" data-pltdoc="x">Running Racket</a></td></tr><tr><td align="right"></td><td><a href="doc-bibliography.html" class="tocviewlink" data-pltdoc="x">Bibliography</a></td></tr><tr><td align="right"></td><td><a href="doc-index.html" class="tocviewlink" data-pltdoc="x">Index</a></td></tr></table></div></div><div class="tocviewlist"><table cellspacing="0" cellpadding="0"><tr><td style="width: 1em;"><a href="javascript:void(0);" title="Expand/Collapse" class="tocviewtoggle" onclick="TocviewToggle(this,&quot;tocview_1&quot;);">&#9660;</a></td><td>12&nbsp;</td><td><a href="Macros.html" class="tocviewlink" data-pltdoc="x">Macros</a></td></tr></table><div class="tocviewsublist" style="display: block;" id="tocview_1"><table cellspacing="0" cellpadding="0"><tr><td align="right">12.1&nbsp;</td><td><a href="stx-patterns.html" class="tocviewlink" data-pltdoc="x">Pattern-<wbr></wbr>Based Syntax Matching</a></td></tr><tr><td align="right">12.2&nbsp;</td><td><a href="stxops.html" class="tocviewlink" data-pltdoc="x">Syntax Object Content</a></td></tr><tr><td align="right">12.3&nbsp;</td><td><a href="stxcmp.html" class="tocviewlink" data-pltdoc="x">Syntax Object Bindings</a></td></tr><tr><td align="right">12.4&nbsp;</td><td><a href="stxtrans.html" class="tocviewlink" data-pltdoc="x">Syntax Transformers</a></td></tr><tr><td align="right">12.5&nbsp;</td><td><a href="stxparam.html" class="tocviewlink" data-pltdoc="x">Syntax Parameters</a></td></tr><tr><td align="right">12.6&nbsp;</td><td><a href="splicing.html" class="tocviewlink" data-pltdoc="x">Local Binding with Splicing Body</a></td></tr><tr><td align="right">12.7&nbsp;</td><td><a href="stxprops.html" class="tocviewlink" data-pltdoc="x">Syntax Object Properties</a></td></tr><tr><td align="right">12.8&nbsp;</td><td><a href="stxcerts.html" class="tocviewlink" data-pltdoc="x">Syntax Taints</a></td></tr><tr><td align="right">12.9&nbsp;</td><td><a href="Expanding_Top-Level_Forms.html" class="tocviewlink" data-pltdoc="x">Expanding Top-<wbr></wbr>Level Forms</a></td></tr><tr><td align="right">12.10&nbsp;</td><td><a href="include.html" class="tocviewlink" data-pltdoc="x">File Inclusion</a></td></tr><tr><td align="right">12.11&nbsp;</td><td><a href="" class="tocviewselflink" data-pltdoc="x">Syntax Utilities</a></td></tr></table></div></div><div class="tocviewlist"><table cellspacing="0" cellpadding="0"><tr><td style="width: 1em;"><a href="javascript:void(0);" title="Expand/Collapse" class="tocviewtoggle" onclick="TocviewToggle(this,&quot;tocview_2&quot;);">&#9658;</a></td><td>12.11&nbsp;</td><td><a href="" class="tocviewselflink" data-pltdoc="x">Syntax Utilities</a></td></tr></table><div class="tocviewsublistbottom" style="display: none;" id="tocview_2"><table cellspacing="0" cellpadding="0"><tr><td align="right">12.11.1&nbsp;</td><td><a href="#%28part._.Creating_formatted_identifiers%29" class="tocviewlink" data-pltdoc="x">Creating formatted identifiers</a></td></tr><tr><td align="right">12.11.2&nbsp;</td><td><a href="#%28part._.Pattern_variables%29" class="tocviewlink" data-pltdoc="x">Pattern variables</a></td></tr><tr><td align="right">12.11.3&nbsp;</td><td><a href="#%28part._.Error_reporting%29" class="tocviewlink" data-pltdoc="x">Error reporting</a></td></tr><tr><td align="right">12.11.4&nbsp;</td><td><a href="#%28part._.Recording_disappeared_uses%29" class="tocviewlink" data-pltdoc="x">Recording disappeared uses</a></td></tr><tr><td align="right">12.11.5&nbsp;</td><td><a href="#%28part._.Miscellaneous_utilities%29" class="tocviewlink" data-pltdoc="x">Miscellaneous utilities</a></td></tr></table></div></div></div><div class="tocsub"><div class="tocsubtitle">On this page:</div><table class="tocsublist" cellspacing="0"><tr><td><span class="tocsublinknumber">12.11.1<tt>&nbsp;</tt></span><a href="#%28part._.Creating_formatted_identifiers%29" class="tocsubseclink" data-pltdoc="x">Creating formatted identifiers</a></td></tr><tr><td><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._format-id%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">format-<wbr></wbr>id</span></span></a></td></tr><tr><td><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._format-symbol%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">format-<wbr></wbr>symbol</span></span></a></td></tr><tr><td><span class="tocsublinknumber">12.11.2<tt>&nbsp;</tt></span><a href="#%28part._.Pattern_variables%29" class="tocsubseclink" data-pltdoc="x">Pattern variables</a></td></tr><tr><td><a href="#%28form._%28%28lib._racket%2Fsyntax..rkt%29._define%2Fwith-syntax%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktStxLink">define/<span class="mywbr"> &nbsp;</span>with-<wbr></wbr>syntax</span></span></a></td></tr><tr><td><span class="tocsublinknumber">12.11.3<tt>&nbsp;</tt></span><a href="#%28part._.Error_reporting%29" class="tocsubseclink" data-pltdoc="x">Error reporting</a></td></tr><tr><td><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._current-syntax-context%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">current-<wbr></wbr>syntax-<wbr></wbr>context</span></span></a></td></tr><tr><td><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._wrong-syntax%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">wrong-<wbr></wbr>syntax</span></span></a></td></tr><tr><td><span class="tocsublinknumber">12.11.4<tt>&nbsp;</tt></span><a href="#%28part._.Recording_disappeared_uses%29" class="tocsubseclink" data-pltdoc="x">Recording disappeared uses</a></td></tr><tr><td><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._current-recorded-disappeared-uses%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">current-<wbr></wbr>recorded-<wbr></wbr>disappeared-<wbr></wbr>uses</span></span></a></td></tr><tr><td><a href="#%28form._%28%28lib._racket%2Fsyntax..rkt%29._with-disappeared-uses%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktStxLink">with-<wbr></wbr>disappeared-<wbr></wbr>uses</span></span></a></td></tr><tr><td><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._syntax-local-value%2Frecord%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">syntax-<wbr></wbr>local-<wbr></wbr>value/<span class="mywbr"> &nbsp;</span>record</span></span></a></td></tr><tr><td><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._record-disappeared-uses%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">record-<wbr></wbr>disappeared-<wbr></wbr>uses</span></span></a></td></tr><tr><td><span class="tocsublinknumber">12.11.5<tt>&nbsp;</tt></span><a href="#%28part._.Miscellaneous_utilities%29" class="tocsubseclink" data-pltdoc="x">Miscellaneous utilities</a></td></tr><tr><td><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._generate-temporary%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">generate-<wbr></wbr>temporary</span></span></a></td></tr><tr><td><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._internal-definition-context-apply%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">internal-<wbr></wbr>definition-<wbr></wbr>context-<wbr></wbr>apply</span></span></a></td></tr><tr><td><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._syntax-local-eval%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">syntax-<wbr></wbr>local-<wbr></wbr>eval</span></span></a></td></tr><tr><td><a href="#%28form._%28%28lib._racket%2Fsyntax..rkt%29._with-syntax%2A%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktStxLink">with-<wbr></wbr>syntax*</span></span></a></td></tr></table></div></div><div class="maincolumn"><div class="main"><div class="navsettop"><span class="navleft"><form class="searchform"><input class="searchbox" style="color: #888;" type="text" value="...search manuals..." title="Enter a search string to search the manuals" onkeypress="return DoSearchKey(event, this, &quot;6.1&quot;, &quot;../&quot;);" onfocus="this.style.color=&quot;black&quot;; this.style.textAlign=&quot;left&quot;; if (this.value == &quot;...search manuals...&quot;) this.value=&quot;&quot;;" onblur="if (this.value.match(/^ *$/)) { this.style.color=&quot;#888&quot;; this.style.textAlign=&quot;center&quot;; this.value=&quot;...search manuals...&quot;; }"/></form>&nbsp;&nbsp;<a href="../index.html" title="up to the documentation top" data-pltdoc="x" onclick="return GotoPLTRoot(&quot;6.1&quot;);">top</a></span><span class="navright">&nbsp;&nbsp;<a href="include.html" title="backward to &quot;12.10 File Inclusion&quot;" data-pltdoc="x">&larr; prev</a>&nbsp;&nbsp;<a href="Macros.html" title="up to &quot;12 Macros&quot;" data-pltdoc="x">up</a>&nbsp;&nbsp;<a href="input-and-output.html" title="forward to &quot;13 Input and Output&quot;" data-pltdoc="x">next &rarr;</a></span>&nbsp;</div><h4 x-source-module="(lib &quot;scribblings/reference/reference.scrbl&quot;)" x-part-tag="&quot;syntax-util&quot;">12.11<tt>&nbsp;</tt><a name="(part._syntax-util)"></a><a name="(mod-path._racket/syntax)"></a>Syntax Utilities</h4><p><div class="SIntrapara"><table cellspacing="0" cellpadding="0" class="defmodule"><tr><td align="left"><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="require.html#%28form._%28%28lib._racket%2Fprivate%2Fbase..rkt%29._require%29%29" class="RktStxLink" data-pltdoc="x">require</a></span><span class="stt"> </span><a href="" class="RktModLink" data-pltdoc="x"><span class="RktSym">racket/syntax</span></a><span class="RktPn">)</span></td><td align="right"><span class="RpackageSpec"><span class="Smaller">&nbsp;package:</span> <span class="stt">base</span></span></td></tr></table></div><div class="SIntrapara">The bindings documented in this section are provided by the <a href="" class="RktModLink" data-pltdoc="x"><span class="RktSym">racket/syntax</span></a> library, not <a href="index.html" class="RktModLink" data-pltdoc="x"><span class="RktSym">racket/base</span></a> or <a href="index.html" class="RktModLink" data-pltdoc="x"><span class="RktSym">racket</span></a>.</div></p><h5 x-source-module="(lib &quot;scribblings/reference/reference.scrbl&quot;)" x-part-tag="&quot;Creating_formatted_identifiers&quot;">12.11.1<tt>&nbsp;</tt><a name="(part._.Creating_formatted_identifiers)"></a>Creating formatted identifiers</h5><p><div class="SIntrapara"><blockquote class="SVInsetFlow"><table cellspacing="0" cellpadding="0" class="boxed RBoxed"><tr><td><blockquote class="SubFlow"><div class="RBackgroundLabel SIEHidden"><div class="RBackgroundLabelInner"><p>procedure</p></div></div><table cellspacing="0" cellpadding="0" class="prototype RForeground"><tr><td><span class="RktPn">(</span><a name="(def._((lib._racket/syntax..rkt)._format-id))"></a><span title="Provided from: racket/syntax | Package: base"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._format-id%29%29" class="RktValDef RktValLink" data-pltdoc="x">format-id</a></span></span></td><td><span class="hspace">&nbsp;</span></td><td><span class="RktVar">lctx</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td></tr><tr><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="RktVar">fmt</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td></tr><tr><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="RktVar">v</span><span class="hspace">&nbsp;</span><span class="RktMeta">...</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td></tr><tr><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span>[</td><td><span class="RktPn">#:source</span><span class="hspace">&nbsp;</span><span class="RktVar">src</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td></tr><tr><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="RktPn">#:props</span><span class="hspace">&nbsp;</span><span class="RktVar">props</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td></tr><tr><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="RktPn">#:cert</span><span class="hspace">&nbsp;</span><span class="RktVar">ignored</span>]<span class="RktPn">)</span></td><td><span class="hspace">&nbsp;</span></td><td>&rarr;</td><td><span class="hspace">&nbsp;</span></td><td><span class="RktSym"><a href="stxops.html#%28def._%28%28lib._racket%2Fprivate%2Fstx..rkt%29._identifier~3f%29%29" class="RktValLink" data-pltdoc="x">identifier?</a></span></td></tr></table></blockquote></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">lctx</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fbase..rkt%29._or%2Fc%29%29" class="RktValLink" data-pltdoc="x">or/c</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="stxops.html#%28def._%28%28quote._~23~25kernel%29._syntax~3f%29%29" class="RktValLink" data-pltdoc="x">syntax?</a></span><span class="hspace">&nbsp;</span><span class="RktVal">#f</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">fmt</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktSym"><a href="strings.html#%28def._%28%28quote._~23~25kernel%29._string~3f%29%29" class="RktValLink" data-pltdoc="x">string?</a></span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">v</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fbase..rkt%29._or%2Fc%29%29" class="RktValLink" data-pltdoc="x">or/c</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="strings.html#%28def._%28%28quote._~23~25kernel%29._string~3f%29%29" class="RktValLink" data-pltdoc="x">string?</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="symbols.html#%28def._%28%28quote._~23~25kernel%29._symbol~3f%29%29" class="RktValLink" data-pltdoc="x">symbol?</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="stxops.html#%28def._%28%28lib._racket%2Fprivate%2Fstx..rkt%29._identifier~3f%29%29" class="RktValLink" data-pltdoc="x">identifier?</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="keywords.html#%28def._%28%28quote._~23~25kernel%29._keyword~3f%29%29" class="RktValLink" data-pltdoc="x">keyword?</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="characters.html#%28def._%28%28quote._~23~25kernel%29._char~3f%29%29" class="RktValLink" data-pltdoc="x">char?</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="number-types.html#%28def._%28%28quote._~23~25kernel%29._number~3f%29%29" class="RktValLink" data-pltdoc="x">number?</a></span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">src</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fbase..rkt%29._or%2Fc%29%29" class="RktValLink" data-pltdoc="x">or/c</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="stxops.html#%28def._%28%28quote._~23~25kernel%29._syntax~3f%29%29" class="RktValLink" data-pltdoc="x">syntax?</a></span><span class="hspace">&nbsp;</span><span class="RktVal">#f</span><span class="RktPn">)</span><span class="hspace">&nbsp;</span>=<span class="hspace">&nbsp;</span><span class="RktVal">#f</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">props</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fbase..rkt%29._or%2Fc%29%29" class="RktValLink" data-pltdoc="x">or/c</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="stxops.html#%28def._%28%28quote._~23~25kernel%29._syntax~3f%29%29" class="RktValLink" data-pltdoc="x">syntax?</a></span><span class="hspace">&nbsp;</span><span class="RktVal">#f</span><span class="RktPn">)</span><span class="hspace">&nbsp;</span>=<span class="hspace">&nbsp;</span><span class="RktVal">#f</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">ignored</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fbase..rkt%29._or%2Fc%29%29" class="RktValLink" data-pltdoc="x">or/c</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="stxops.html#%28def._%28%28quote._~23~25kernel%29._syntax~3f%29%29" class="RktValLink" data-pltdoc="x">syntax?</a></span><span class="hspace">&nbsp;</span><span class="RktVal">#f</span><span class="RktPn">)</span><span class="hspace">&nbsp;</span>=<span class="hspace">&nbsp;</span><span class="RktVal">#f</span></td></tr></table></blockquote></div><div class="SIntrapara">Like <span class="RktSym"><a href="Writing.html#%28def._%28%28quote._~23~25kernel%29._format%29%29" class="RktValLink" data-pltdoc="x">format</a></span>, but produces an identifier using <span class="RktVar">lctx</span>
for the lexical context, <span class="RktVar">src</span> for the source location, and
<span class="RktVar">props</span> for the properties. An argument supplied with
<span class="RktPn">#:cert</span> is ignored. (See <span class="RktSym"><a href="stxops.html#%28def._%28%28quote._~23~25kernel%29._datum-~3esyntax%29%29" class="RktValLink" data-pltdoc="x">datum-&gt;syntax</a></span>.)</div></p><p>The format string must use only <span class="RktInBG"><span class="hspace"></span><span class="RktIn">~a</span><span class="hspace"></span></span> placeholders. Identifiers
in the argument list are automatically converted to symbols.</p><p><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><p>Examples:</p></td></tr><tr><td><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="stt">&gt; </span><span class="RktPn">(</span><span class="RktSym"><a href="define.html#%28form._%28%28lib._racket%2Fprivate%2Fbase..rkt%29._define-syntax%29%29" class="RktStxLink" data-pltdoc="x">define-syntax</a></span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym">make-pred</span><span class="hspace">&nbsp;</span><span class="RktSym">stx</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="hspace">&nbsp;&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="stx-patterns.html#%28form._%28%28lib._racket%2Fprivate%2Fstxcase-scheme..rkt%29._syntax-case%29%29" class="RktStxLink" data-pltdoc="x">syntax-case</a></span><span class="hspace">&nbsp;</span><span class="RktSym">stx</span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="hspace">&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="RktPn">[</span><span class="RktPn">(</span><span class="RktSym">make-pred</span><span class="hspace">&nbsp;</span><span class="RktSym">name</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="hspace">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._format-id%29%29" class="RktValLink" data-pltdoc="x">format-id</a></span><span class="hspace">&nbsp;</span><span class="RktRdr">#'</span><span class="RktSym">name</span><span class="hspace">&nbsp;</span><span class="RktVal">"~a?"</span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="stxops.html#%28def._%28%28quote._~23~25kernel%29._syntax-e%29%29" class="RktValLink" data-pltdoc="x">syntax-e</a></span><span class="hspace">&nbsp;</span><span class="RktRdr">#'</span><span class="RktSym">name</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr></table></td></tr><tr><td><table cellspacing="0" cellpadding="0"><tr><td></td></tr></table></td></tr><tr><td><span class="stt">&gt; </span><span class="RktPn">(</span><span class="RktSym">make-pred</span><span class="hspace">&nbsp;</span><span class="RktSym">pair</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktRes">#&lt;procedure:pair?&gt;</span></p></td></tr><tr><td><span class="stt">&gt; </span><span class="RktPn">(</span><span class="RktSym">make-pred</span><span class="hspace">&nbsp;</span><span class="RktSym">none-such</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktErr">none-such?: undefined;</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace">&nbsp;</span><span class="RktErr">cannot reference undefined identifier</span></p></td></tr><tr><td><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="stt">&gt; </span><span class="RktPn">(</span><span class="RktSym"><a href="define.html#%28form._%28%28lib._racket%2Fprivate%2Fbase..rkt%29._define-syntax%29%29" class="RktStxLink" data-pltdoc="x">define-syntax</a></span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym">better-make-pred</span><span class="hspace">&nbsp;</span><span class="RktSym">stx</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="hspace">&nbsp;&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="stx-patterns.html#%28form._%28%28lib._racket%2Fprivate%2Fstxcase-scheme..rkt%29._syntax-case%29%29" class="RktStxLink" data-pltdoc="x">syntax-case</a></span><span class="hspace">&nbsp;</span><span class="RktSym">stx</span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="hspace">&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="RktPn">[</span><span class="RktPn">(</span><span class="RktSym">better-make-pred</span><span class="hspace">&nbsp;</span><span class="RktSym">name</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="hspace">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._format-id%29%29" class="RktValLink" data-pltdoc="x">format-id</a></span><span class="hspace">&nbsp;</span><span class="RktRdr">#'</span><span class="RktSym">name</span><span class="hspace">&nbsp;</span><span class="RktPn">#:source</span><span class="hspace">&nbsp;</span><span class="RktRdr">#'</span><span class="RktSym">name</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="hspace">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="RktVal">"~a?"</span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="stxops.html#%28def._%28%28quote._~23~25kernel%29._syntax-e%29%29" class="RktValLink" data-pltdoc="x">syntax-e</a></span><span class="hspace">&nbsp;</span><span class="RktRdr">#'</span><span class="RktSym">name</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr></table></td></tr><tr><td><table cellspacing="0" cellpadding="0"><tr><td></td></tr></table></td></tr><tr><td><span class="stt">&gt; </span><span class="RktPn">(</span><span class="RktSym">better-make-pred</span><span class="hspace">&nbsp;</span><span class="RktSym">none-such</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktErr">none-such?: undefined;</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace">&nbsp;</span><span class="RktErr">cannot reference undefined identifier</span></p></td></tr></table></blockquote></td></tr></table></p><p>(Scribble doesn&rsquo;t show it, but the DrRacket pinpoints the location of
the second error but not of the first.)</p><p><div class="SIntrapara"><blockquote class="SVInsetFlow"><table cellspacing="0" cellpadding="0" class="boxed RBoxed"><tr><td><blockquote class="SubFlow"><div class="RBackgroundLabel SIEHidden"><div class="RBackgroundLabelInner"><p>procedure</p></div></div><p class="RForeground"><span class="RktPn">(</span><a name="(def._((lib._racket/syntax..rkt)._format-symbol))"></a><span title="Provided from: racket/syntax | Package: base"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._format-symbol%29%29" class="RktValDef RktValLink" data-pltdoc="x">format-symbol</a></span></span><span class="hspace">&nbsp;</span><span class="RktVar">fmt</span><span class="hspace">&nbsp;</span><span class="RktVar">v</span><span class="hspace">&nbsp;</span><span class="RktMeta">...</span><span class="RktPn">)</span><span class="hspace">&nbsp;</span>&rarr;<span class="hspace">&nbsp;</span><span class="RktSym"><a href="symbols.html#%28def._%28%28quote._~23~25kernel%29._symbol~3f%29%29" class="RktValLink" data-pltdoc="x">symbol?</a></span></p></blockquote></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">fmt</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktSym"><a href="strings.html#%28def._%28%28quote._~23~25kernel%29._string~3f%29%29" class="RktValLink" data-pltdoc="x">string?</a></span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">v</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fbase..rkt%29._or%2Fc%29%29" class="RktValLink" data-pltdoc="x">or/c</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="strings.html#%28def._%28%28quote._~23~25kernel%29._string~3f%29%29" class="RktValLink" data-pltdoc="x">string?</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="symbols.html#%28def._%28%28quote._~23~25kernel%29._symbol~3f%29%29" class="RktValLink" data-pltdoc="x">symbol?</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="stxops.html#%28def._%28%28lib._racket%2Fprivate%2Fstx..rkt%29._identifier~3f%29%29" class="RktValLink" data-pltdoc="x">identifier?</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="keywords.html#%28def._%28%28quote._~23~25kernel%29._keyword~3f%29%29" class="RktValLink" data-pltdoc="x">keyword?</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="characters.html#%28def._%28%28quote._~23~25kernel%29._char~3f%29%29" class="RktValLink" data-pltdoc="x">char?</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="number-types.html#%28def._%28%28quote._~23~25kernel%29._number~3f%29%29" class="RktValLink" data-pltdoc="x">number?</a></span><span class="RktPn">)</span></td></tr></table></blockquote></div><div class="SIntrapara">Like <span class="RktSym"><a href="Writing.html#%28def._%28%28quote._~23~25kernel%29._format%29%29" class="RktValLink" data-pltdoc="x">format</a></span>, but produces a symbol. The format string must
use only <span class="RktInBG"><span class="hspace"></span><span class="RktIn">~a</span><span class="hspace"></span></span> placeholders. Identifiers in the argument list
are automatically converted to symbols.</div></p><p><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><p>Example:</p></td></tr><tr><td><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="stt">&gt; </span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._format-symbol%29%29" class="RktValLink" data-pltdoc="x">format-symbol</a></span><span class="hspace">&nbsp;</span><span class="RktVal">"make-~a"</span><span class="hspace">&nbsp;</span><span class="RktVal">'</span><span class="RktVal">triple</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktRes">'make-triple</span></p></td></tr></table></blockquote></td></tr></table></p><h5 x-source-module="(lib &quot;scribblings/reference/reference.scrbl&quot;)" x-part-tag="&quot;Pattern_variables&quot;">12.11.2<tt>&nbsp;</tt><a name="(part._.Pattern_variables)"></a>Pattern variables</h5><p><div class="SIntrapara"><blockquote class="SVInsetFlow"><table cellspacing="0" cellpadding="0" class="boxed RBoxed"><tr><td><blockquote class="SubFlow"><div class="RBackgroundLabel SIEHidden"><div class="RBackgroundLabelInner"><p>syntax</p></div></div><p class="RForeground"><span class="RktPn">(</span><a name="(form._((lib._racket/syntax..rkt)._define/with-syntax))"></a><span title="Provided from: racket/syntax | Package: base"><span class="RktSym"><a href="#%28form._%28%28lib._racket%2Fsyntax..rkt%29._define%2Fwith-syntax%29%29" class="RktStxDef RktStxLink" data-pltdoc="x">define/with-syntax</a></span></span><span class="hspace">&nbsp;</span><span class="RktVar">pattern</span><span class="hspace">&nbsp;</span><span class="RktVar">stx-expr</span><span class="RktPn">)</span></p></blockquote></td></tr><tr><td><span class="stt">&nbsp;</span></td></tr><tr><td><table cellspacing="0" cellpadding="0" class="argcontract"><tr><td><span class="hspace">&nbsp;&nbsp;</span></td><td><span class="RktVar">stx-expr</span></td><td><span class="hspace">&nbsp;</span></td><td>:</td><td><span class="hspace">&nbsp;</span></td><td><span class="RktSym"><a href="stxops.html#%28def._%28%28quote._~23~25kernel%29._syntax~3f%29%29" class="RktValLink" data-pltdoc="x">syntax?</a></span></td></tr></table></td></tr></table></blockquote></div><div class="SIntrapara">Definition form of <span class="RktSym"><a href="stx-patterns.html#%28form._%28%28lib._racket%2Fprivate%2Fstxcase-scheme..rkt%29._with-syntax%29%29" class="RktStxLink" data-pltdoc="x">with-syntax</a></span>. That is, it matches the
syntax object result of <span class="RktSym">expr</span> against <span class="RktVar">pattern</span> and
creates pattern variable definitions for the pattern variables of
<span class="RktVar">pattern</span>.</div></p><p><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><p>Examples:</p></td></tr><tr><td><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="stt">&gt; </span><span class="RktPn">(</span><span class="RktSym"><a href="#%28form._%28%28lib._racket%2Fsyntax..rkt%29._define%2Fwith-syntax%29%29" class="RktStxLink" data-pltdoc="x">define/with-syntax</a></span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym">px</span><span class="hspace">&nbsp;</span><span class="RktMeta"><a href="stx-patterns.html#%28form._%28%28lib._racket%2Fprivate%2Fstxcase-scheme..rkt%29._......%29%29" class="RktStxLink" data-pltdoc="x">...</a></span><span class="RktPn">)</span><span class="hspace">&nbsp;</span><span class="RktRdr">#'</span><span class="RktPn">(</span><span class="RktSym">a</span><span class="hspace">&nbsp;</span><span class="RktSym">b</span><span class="hspace">&nbsp;</span><span class="RktSym">c</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><table cellspacing="0" cellpadding="0"><tr><td></td></tr></table></td></tr><tr><td><span class="stt">&gt; </span><span class="RktPn">(</span><span class="RktSym"><a href="#%28form._%28%28lib._racket%2Fsyntax..rkt%29._define%2Fwith-syntax%29%29" class="RktStxLink" data-pltdoc="x">define/with-syntax</a></span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym">tmp</span><span class="hspace">&nbsp;</span><span class="RktMeta"><a href="stx-patterns.html#%28form._%28%28lib._racket%2Fprivate%2Fstxcase-scheme..rkt%29._......%29%29" class="RktStxLink" data-pltdoc="x">...</a></span><span class="RktPn">)</span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="stxops.html#%28def._%28%28lib._racket%2Fprivate%2Fstxcase-scheme..rkt%29._generate-temporaries%29%29" class="RktValLink" data-pltdoc="x">generate-temporaries</a></span><span class="hspace">&nbsp;</span><span class="RktRdr">#'</span><span class="RktPn">(</span><span class="RktSym">px</span><span class="hspace">&nbsp;</span><span class="RktMeta"><a href="stx-patterns.html#%28form._%28%28lib._racket%2Fprivate%2Fstxcase-scheme..rkt%29._......%29%29" class="RktStxLink" data-pltdoc="x">...</a></span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><table cellspacing="0" cellpadding="0"><tr><td></td></tr></table></td></tr><tr><td><span class="stt">&gt; </span><span class="RktRdr">#'</span><span class="RktPn">(</span><span class="RktPn">[</span><span class="RktSym">tmp</span><span class="hspace">&nbsp;</span><span class="RktSym">px</span><span class="RktPn">]</span><span class="hspace">&nbsp;</span><span class="RktMeta"><a href="stx-patterns.html#%28form._%28%28lib._racket%2Fprivate%2Fstxcase-scheme..rkt%29._......%29%29" class="RktStxLink" data-pltdoc="x">...</a></span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktRes">#&lt;syntax:11:0 ((a9 a) (b10 b) (c11 c))&gt;</span></p></td></tr><tr><td><span class="stt">&gt; </span><span class="RktPn">(</span><span class="RktSym"><a href="#%28form._%28%28lib._racket%2Fsyntax..rkt%29._define%2Fwith-syntax%29%29" class="RktStxLink" data-pltdoc="x">define/with-syntax</a></span><span class="hspace">&nbsp;</span><span class="RktSym">name</span><span class="hspace">&nbsp;</span><span class="RktRdr">#'</span><span class="RktSym">Alice</span><span class="RktPn">)</span></td></tr><tr><td><table cellspacing="0" cellpadding="0"><tr><td></td></tr></table></td></tr><tr><td><span class="stt">&gt; </span><span class="RktRdr">#'</span><span class="RktPn">(</span><span class="RktSym">hello</span><span class="hspace">&nbsp;</span><span class="RktSym">name</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktRes">#&lt;syntax:13:0 (hello Alice)&gt;</span></p></td></tr></table></blockquote></td></tr></table></p><h5 x-source-module="(lib &quot;scribblings/reference/reference.scrbl&quot;)" x-part-tag="&quot;Error_reporting&quot;">12.11.3<tt>&nbsp;</tt><a name="(part._.Error_reporting)"></a>Error reporting</h5><p><div class="SIntrapara"><blockquote class="SVInsetFlow"><table cellspacing="0" cellpadding="0" class="boxed RBoxed"><tr><td><blockquote class="SubFlow"><div class="RBackgroundLabel SIEHidden"><div class="RBackgroundLabelInner"><p>parameter</p></div></div><p class="RForeground"><span class="RktPn">(</span><a name="(def._((lib._racket/syntax..rkt)._current-syntax-context))"></a><span title="Provided from: racket/syntax | Package: base"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._current-syntax-context%29%29" class="RktValDef RktValLink" data-pltdoc="x">current-syntax-context</a></span></span><span class="RktPn"></span><span class="RktPn">)</span><span class="hspace">&nbsp;</span>&rarr;<span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fbase..rkt%29._or%2Fc%29%29" class="RktValLink" data-pltdoc="x">or/c</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="stxops.html#%28def._%28%28quote._~23~25kernel%29._syntax~3f%29%29" class="RktValLink" data-pltdoc="x">syntax?</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fprivate%2Fmisc..rkt%29._false%2Fc%29%29" class="RktValLink" data-pltdoc="x">false/c</a></span><span class="RktPn">)</span></p></blockquote></td></tr><tr><td><span class="RktPn">(</span><span title="Provided from: racket/syntax | Package: base"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._current-syntax-context%29%29" class="RktValDef RktValLink" data-pltdoc="x">current-syntax-context</a></span></span><span class="hspace">&nbsp;</span><span class="RktVar">stx</span><span class="RktPn">)</span><span class="hspace">&nbsp;</span>&rarr;<span class="hspace">&nbsp;</span><span class="RktSym"><a href="void.html#%28def._%28%28quote._~23~25kernel%29._void~3f%29%29" class="RktValLink" data-pltdoc="x">void?</a></span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">stx</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fbase..rkt%29._or%2Fc%29%29" class="RktValLink" data-pltdoc="x">or/c</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="stxops.html#%28def._%28%28quote._~23~25kernel%29._syntax~3f%29%29" class="RktValLink" data-pltdoc="x">syntax?</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fprivate%2Fmisc..rkt%29._false%2Fc%29%29" class="RktValLink" data-pltdoc="x">false/c</a></span><span class="RktPn">)</span></td></tr></table></blockquote></div><div class="SIntrapara">The current contextual syntax object, defaulting to <span class="RktVal">#f</span>.  It
determines the special form name that prefixes syntax errors created
by <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._wrong-syntax%29%29" class="RktValLink" data-pltdoc="x">wrong-syntax</a></span>.</div></p><p><div class="SIntrapara"><blockquote class="SVInsetFlow"><table cellspacing="0" cellpadding="0" class="boxed RBoxed"><tr><td><blockquote class="SubFlow"><div class="RBackgroundLabel SIEHidden"><div class="RBackgroundLabelInner"><p>procedure</p></div></div><p class="RForeground"><span class="RktPn">(</span><a name="(def._((lib._racket/syntax..rkt)._wrong-syntax))"></a><span title="Provided from: racket/syntax | Package: base"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._wrong-syntax%29%29" class="RktValDef RktValLink" data-pltdoc="x">wrong-syntax</a></span></span><span class="hspace">&nbsp;</span><span class="RktVar">stx</span><span class="hspace">&nbsp;</span><span class="RktVar">format-string</span><span class="hspace">&nbsp;</span><span class="RktVar">v</span><span class="hspace">&nbsp;</span><span class="RktMeta">...</span><span class="RktPn">)</span><span class="hspace">&nbsp;</span>&rarr;<span class="hspace">&nbsp;</span><span class="RktSym"><a href="data-structure-contracts.html#%28form._%28%28lib._racket%2Fcontract%2Fprivate%2Fmisc..rkt%29._any%29%29" class="RktStxLink" data-pltdoc="x">any</a></span></p></blockquote></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">stx</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktSym"><a href="stxops.html#%28def._%28%28quote._~23~25kernel%29._syntax~3f%29%29" class="RktValLink" data-pltdoc="x">syntax?</a></span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">format-string</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktSym"><a href="strings.html#%28def._%28%28quote._~23~25kernel%29._string~3f%29%29" class="RktValLink" data-pltdoc="x">string?</a></span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">v</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fprivate%2Fmisc..rkt%29._any%2Fc%29%29" class="RktValLink" data-pltdoc="x">any/c</a></span></td></tr></table></blockquote></div><div class="SIntrapara">Raises a syntax error using the result of
<span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._current-syntax-context%29%29" class="RktValLink" data-pltdoc="x">current-syntax-context</a></span><span class="RktPn">)</span> as the &ldquo;major&rdquo; syntax object and
the provided <span class="RktVar">stx</span> as the specific syntax object. (The latter,
<span class="RktVar">stx</span>, is usually the one highlighted by DrRacket.) The error
message is constructed using the format string and arguments, and it
is prefixed with the special form name as described under
<span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._current-syntax-context%29%29" class="RktValLink" data-pltdoc="x">current-syntax-context</a></span>.</div></p><p><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><p>Examples:</p></td></tr><tr><td><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="stt">&gt; </span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._wrong-syntax%29%29" class="RktValLink" data-pltdoc="x">wrong-syntax</a></span><span class="hspace">&nbsp;</span><span class="RktRdr">#'</span><span class="RktSym">here</span><span class="hspace">&nbsp;</span><span class="RktVal">"expected ~s"</span><span class="hspace">&nbsp;</span><span class="RktVal">'</span><span class="RktVal">there</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktErr">?: expected there</span></p></td></tr><tr><td><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="stt">&gt; </span><span class="RktPn">(</span><span class="RktSym"><a href="parameters.html#%28form._%28%28lib._racket%2Fprivate%2Fmore-scheme..rkt%29._parameterize%29%29" class="RktStxLink" data-pltdoc="x">parameterize</a></span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktPn">[</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._current-syntax-context%29%29" class="RktValLink" data-pltdoc="x">current-syntax-context</a></span><span class="hspace">&nbsp;</span><span class="RktRdr">#'</span><span class="RktPn">(</span><span class="RktSym">look</span><span class="hspace">&nbsp;</span><span class="RktSym">over</span><span class="hspace">&nbsp;</span><span class="RktSym">here</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="hspace">&nbsp;&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._wrong-syntax%29%29" class="RktValLink" data-pltdoc="x">wrong-syntax</a></span><span class="hspace">&nbsp;</span><span class="RktRdr">#'</span><span class="RktSym">here</span><span class="hspace">&nbsp;</span><span class="RktVal">"expected ~s"</span><span class="hspace">&nbsp;</span><span class="RktVal">'</span><span class="RktVal">there</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr></table></td></tr><tr><td><p><span class="RktErr">eval:15:0: look: expected there</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace">&nbsp;&nbsp;</span><span class="RktErr">at: here</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace">&nbsp;&nbsp;</span><span class="RktErr">in: (look over here)</span></p></td></tr></table></blockquote></td></tr></table></p><p><div class="SIntrapara">A macro using <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._wrong-syntax%29%29" class="RktValLink" data-pltdoc="x">wrong-syntax</a></span> might set the syntax context at the very
beginning of its transformation as follows:
</div><div class="SIntrapara"><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="define.html#%28form._%28%28lib._racket%2Fprivate%2Fbase..rkt%29._define-syntax%29%29" class="RktStxLink" data-pltdoc="x">define-syntax</a></span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym">my-macro</span><span class="hspace">&nbsp;</span><span class="RktVar">stx</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="parameters.html#%28form._%28%28lib._racket%2Fprivate%2Fmore-scheme..rkt%29._parameterize%29%29" class="RktStxLink" data-pltdoc="x">parameterize</a></span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktPn">[</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._current-syntax-context%29%29" class="RktValLink" data-pltdoc="x">current-syntax-context</a></span><span class="hspace">&nbsp;</span><span class="RktVar">stx</span><span class="RktPn">]</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="stx-patterns.html#%28form._%28%28lib._racket%2Fprivate%2Fstxcase-scheme..rkt%29._syntax-case%29%29" class="RktStxLink" data-pltdoc="x">syntax-case</a></span><span class="hspace">&nbsp;</span><span class="RktVar">stx</span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="RktVar">__</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr></table></blockquote></div><div class="SIntrapara">Then any calls to <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._wrong-syntax%29%29" class="RktValLink" data-pltdoc="x">wrong-syntax</a></span> during the macro&rsquo;s
transformation will refer to <span class="RktSym">my-macro</span> (more precisely, the name that
referred to <span class="RktSym">my-macro</span> where the macro was used, which may be
different due to renaming, prefixing, etc).</div></p><h5 x-source-module="(lib &quot;scribblings/reference/reference.scrbl&quot;)" x-part-tag="&quot;Recording_disappeared_uses&quot;">12.11.4<tt>&nbsp;</tt><a name="(part._.Recording_disappeared_uses)"></a>Recording disappeared uses</h5><p><div class="SIntrapara"><blockquote class="SVInsetFlow"><table cellspacing="0" cellpadding="0" class="boxed RBoxed"><tr><td><blockquote class="SubFlow"><div class="RBackgroundLabel SIEHidden"><div class="RBackgroundLabelInner"><p>parameter</p></div></div><p class="RForeground"><span class="RktPn">(</span><a name="(def._((lib._racket/syntax..rkt)._current-recorded-disappeared-uses))"></a><span title="Provided from: racket/syntax | Package: base"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._current-recorded-disappeared-uses%29%29" class="RktValDef RktValLink" data-pltdoc="x">current-recorded-disappeared-uses</a></span></span><span class="RktPn"></span><span class="RktPn">)</span></p></blockquote></td></tr><tr><td><span class="hspace">&nbsp;</span>&rarr;<span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fbase..rkt%29._or%2Fc%29%29" class="RktValLink" data-pltdoc="x">or/c</a></span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fprivate%2Fmisc..rkt%29._listof%29%29" class="RktValLink" data-pltdoc="x">listof</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="stxops.html#%28def._%28%28lib._racket%2Fprivate%2Fstx..rkt%29._identifier~3f%29%29" class="RktValLink" data-pltdoc="x">identifier?</a></span><span class="RktPn">)</span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fprivate%2Fmisc..rkt%29._false%2Fc%29%29" class="RktValLink" data-pltdoc="x">false/c</a></span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span title="Provided from: racket/syntax | Package: base"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._current-recorded-disappeared-uses%29%29" class="RktValDef RktValLink" data-pltdoc="x">current-recorded-disappeared-uses</a></span></span><span class="hspace">&nbsp;</span><span class="RktVar">ids</span><span class="RktPn">)</span><span class="hspace">&nbsp;</span>&rarr;<span class="hspace">&nbsp;</span><span class="RktSym"><a href="void.html#%28def._%28%28quote._~23~25kernel%29._void~3f%29%29" class="RktValLink" data-pltdoc="x">void?</a></span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">ids</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fbase..rkt%29._or%2Fc%29%29" class="RktValLink" data-pltdoc="x">or/c</a></span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fprivate%2Fmisc..rkt%29._listof%29%29" class="RktValLink" data-pltdoc="x">listof</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="stxops.html#%28def._%28%28lib._racket%2Fprivate%2Fstx..rkt%29._identifier~3f%29%29" class="RktValLink" data-pltdoc="x">identifier?</a></span><span class="RktPn">)</span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fprivate%2Fmisc..rkt%29._false%2Fc%29%29" class="RktValLink" data-pltdoc="x">false/c</a></span><span class="RktPn">)</span></td></tr></table></blockquote></div><div class="SIntrapara">Parameter for tracking disappeared uses. Tracking is &ldquo;enabled&rdquo; when
the parameter has a non-false value. This is done automatically by
forms like <span class="RktSym"><a href="#%28form._%28%28lib._racket%2Fsyntax..rkt%29._with-disappeared-uses%29%29" class="RktStxLink" data-pltdoc="x">with-disappeared-uses</a></span>.</div></p><p><div class="SIntrapara"><blockquote class="SVInsetFlow"><table cellspacing="0" cellpadding="0" class="boxed RBoxed"><tr><td><blockquote class="SubFlow"><div class="RBackgroundLabel SIEHidden"><div class="RBackgroundLabelInner"><p>syntax</p></div></div><p class="RForeground"><span class="RktPn">(</span><a name="(form._((lib._racket/syntax..rkt)._with-disappeared-uses))"></a><span title="Provided from: racket/syntax | Package: base"><span class="RktSym"><a href="#%28form._%28%28lib._racket%2Fsyntax..rkt%29._with-disappeared-uses%29%29" class="RktStxDef RktStxLink" data-pltdoc="x">with-disappeared-uses</a></span></span><span class="hspace">&nbsp;</span><span class="RktVar">stx-expr</span><span class="RktPn">)</span></p></blockquote></td></tr><tr><td><span class="stt">&nbsp;</span></td></tr><tr><td><table cellspacing="0" cellpadding="0" class="argcontract"><tr><td><span class="hspace">&nbsp;&nbsp;</span></td><td><span class="RktVar">stx-expr</span></td><td><span class="hspace">&nbsp;</span></td><td>:</td><td><span class="hspace">&nbsp;</span></td><td><span class="RktSym"><a href="stxops.html#%28def._%28%28quote._~23~25kernel%29._syntax~3f%29%29" class="RktValLink" data-pltdoc="x">syntax?</a></span></td></tr></table></td></tr></table></blockquote></div><div class="SIntrapara">Evaluates the <span class="RktVar">stx-expr</span>, catching identifiers looked up using
<span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._syntax-local-value%2Frecord%29%29" class="RktValLink" data-pltdoc="x">syntax-local-value/record</a></span>. Adds the caught identifiers to the
<span class="RktVal">'</span><span class="RktVal">disappeared-uses</span> syntax property of the resulting syntax
object.</div></p><p><div class="SIntrapara"><blockquote class="SVInsetFlow"><table cellspacing="0" cellpadding="0" class="boxed RBoxed"><tr><td><blockquote class="SubFlow"><div class="RBackgroundLabel SIEHidden"><div class="RBackgroundLabelInner"><p>procedure</p></div></div><p class="RForeground"><span class="RktPn">(</span><a name="(def._((lib._racket/syntax..rkt)._syntax-local-value/record))"></a><span title="Provided from: racket/syntax | Package: base"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._syntax-local-value%2Frecord%29%29" class="RktValDef RktValLink" data-pltdoc="x">syntax-local-value/record</a></span></span><span class="hspace">&nbsp;</span><span class="RktVar">id</span><span class="hspace">&nbsp;</span><span class="RktVar">predicate</span><span class="RktPn">)</span><span class="hspace">&nbsp;</span>&rarr;<span class="hspace">&nbsp;</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fprivate%2Fmisc..rkt%29._any%2Fc%29%29" class="RktValLink" data-pltdoc="x">any/c</a></span></p></blockquote></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">id</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktSym"><a href="stxops.html#%28def._%28%28lib._racket%2Fprivate%2Fstx..rkt%29._identifier~3f%29%29" class="RktValLink" data-pltdoc="x">identifier?</a></span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">predicate</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="function-contracts.html#%28form._%28%28lib._racket%2Fcontract%2Fbase..rkt%29._-~3e%29%29" class="RktStxLink" data-pltdoc="x"><span class="nobreak">-&gt;</span></a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fprivate%2Fmisc..rkt%29._any%2Fc%29%29" class="RktValLink" data-pltdoc="x">any/c</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="booleans.html#%28def._%28%28quote._~23~25kernel%29._boolean~3f%29%29" class="RktValLink" data-pltdoc="x">boolean?</a></span><span class="RktPn">)</span></td></tr></table></blockquote></div><div class="SIntrapara">Looks up <span class="RktVar">id</span> in the syntactic environment (as
<span class="RktSym"><a href="stxtrans.html#%28def._%28%28quote._~23~25kernel%29._syntax-local-value%29%29" class="RktValLink" data-pltdoc="x">syntax-local-value</a></span>). If the lookup succeeds and returns a
value satisfying the predicate, the value is returned and <span class="RktVar">id</span>
is recorded as a disappeared use by calling <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._record-disappeared-uses%29%29" class="RktValLink" data-pltdoc="x">record-disappeared-uses</a></span>.
If the lookup fails or if the value
does not satisfy the predicate, <span class="RktVal">#f</span> is returned and the
identifier is not recorded as a disappeared use.</div></p><p><div class="SIntrapara"><blockquote class="SVInsetFlow"><table cellspacing="0" cellpadding="0" class="boxed RBoxed"><tr><td><blockquote class="SubFlow"><div class="RBackgroundLabel SIEHidden"><div class="RBackgroundLabelInner"><p>procedure</p></div></div><p class="RForeground"><span class="RktPn">(</span><a name="(def._((lib._racket/syntax..rkt)._record-disappeared-uses))"></a><span title="Provided from: racket/syntax | Package: base"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._record-disappeared-uses%29%29" class="RktValDef RktValLink" data-pltdoc="x">record-disappeared-uses</a></span></span><span class="hspace">&nbsp;</span><span class="RktVar">ids</span><span class="RktPn">)</span><span class="hspace">&nbsp;</span>&rarr;<span class="hspace">&nbsp;</span><span class="RktSym"><a href="void.html#%28def._%28%28quote._~23~25kernel%29._void~3f%29%29" class="RktValLink" data-pltdoc="x">void?</a></span></p></blockquote></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">ids</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fprivate%2Fmisc..rkt%29._listof%29%29" class="RktValLink" data-pltdoc="x">listof</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="stxops.html#%28def._%28%28lib._racket%2Fprivate%2Fstx..rkt%29._identifier~3f%29%29" class="RktValLink" data-pltdoc="x">identifier?</a></span><span class="RktPn">)</span></td></tr></table></blockquote></div><div class="SIntrapara">Add <span class="RktVar">ids</span> to <span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._current-recorded-disappeared-uses%29%29" class="RktValLink" data-pltdoc="x">current-recorded-disappeared-uses</a></span><span class="RktPn">)</span> after calling
<span class="RktSym"><a href="stxtrans.html#%28def._%28%28quote._~23~25kernel%29._syntax-local-introduce%29%29" class="RktValLink" data-pltdoc="x">syntax-local-introduce</a></span> on each of the identifiers.</div></p><p>If not used within the extent of a <span class="RktSym"><a href="#%28form._%28%28lib._racket%2Fsyntax..rkt%29._with-disappeared-uses%29%29" class="RktStxLink" data-pltdoc="x">with-disappeared-uses</a></span>
form or similar, has no effect.</p><h5 x-source-module="(lib &quot;scribblings/reference/reference.scrbl&quot;)" x-part-tag="&quot;Miscellaneous_utilities&quot;">12.11.5<tt>&nbsp;</tt><a name="(part._.Miscellaneous_utilities)"></a>Miscellaneous utilities</h5><p><div class="SIntrapara"><blockquote class="SVInsetFlow"><table cellspacing="0" cellpadding="0" class="boxed RBoxed"><tr><td><blockquote class="SubFlow"><div class="RBackgroundLabel SIEHidden"><div class="RBackgroundLabelInner"><p>procedure</p></div></div><p class="RForeground"><span class="RktPn">(</span><a name="(def._((lib._racket/syntax..rkt)._generate-temporary))"></a><span title="Provided from: racket/syntax | Package: base"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._generate-temporary%29%29" class="RktValDef RktValLink" data-pltdoc="x">generate-temporary</a></span></span><span class="hspace">&nbsp;</span>[<span class="RktVar">name-base</span>]<span class="RktPn">)</span><span class="hspace">&nbsp;</span>&rarr;<span class="hspace">&nbsp;</span><span class="RktSym"><a href="stxops.html#%28def._%28%28lib._racket%2Fprivate%2Fstx..rkt%29._identifier~3f%29%29" class="RktValLink" data-pltdoc="x">identifier?</a></span></p></blockquote></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">name-base</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fprivate%2Fmisc..rkt%29._any%2Fc%29%29" class="RktValLink" data-pltdoc="x">any/c</a></span><span class="hspace">&nbsp;</span>=<span class="hspace">&nbsp;</span><span class="RktVal">'</span><span class="RktVal">g</span></td></tr></table></blockquote></div><div class="SIntrapara">Generates one fresh identifier. Singular form of
<span class="RktSym"><a href="stxops.html#%28def._%28%28lib._racket%2Fprivate%2Fstxcase-scheme..rkt%29._generate-temporaries%29%29" class="RktValLink" data-pltdoc="x">generate-temporaries</a></span>. If <span class="RktVar">name-base</span> is supplied, it
is used as the basis for the identifier&rsquo;s name.</div></p><p><div class="SIntrapara"><blockquote class="SVInsetFlow"><table cellspacing="0" cellpadding="0" class="boxed RBoxed"><tr><td><blockquote class="SubFlow"><div class="RBackgroundLabel SIEHidden"><div class="RBackgroundLabelInner"><p>procedure</p></div></div><table cellspacing="0" cellpadding="0" class="prototype RForeground"><tr><td><span class="RktPn">(</span><a name="(def._((lib._racket/syntax..rkt)._internal-definition-context-apply))"></a><span title="Provided from: racket/syntax | Package: base"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._internal-definition-context-apply%29%29" class="RktValDef RktValLink" data-pltdoc="x">internal-definition-context-apply</a></span></span></td><td><span class="hspace">&nbsp;</span></td><td><span class="RktVar">intdef-ctx</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td></tr><tr><td><span class="hspace">&nbsp;</span></td><td><span class="hspace">&nbsp;</span></td><td><span class="RktVar">stx</span><span class="RktPn">)</span></td><td><span class="hspace">&nbsp;</span></td><td>&rarr;</td><td><span class="hspace">&nbsp;</span></td><td><span class="RktSym"><a href="stxops.html#%28def._%28%28quote._~23~25kernel%29._syntax~3f%29%29" class="RktValLink" data-pltdoc="x">syntax?</a></span></td></tr></table></blockquote></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">intdef-ctx</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktSym"><a href="stxtrans.html#%28def._%28%28quote._~23~25kernel%29._internal-definition-context~3f%29%29" class="RktValLink" data-pltdoc="x">internal-definition-context?</a></span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">stx</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktSym"><a href="stxops.html#%28def._%28%28quote._~23~25kernel%29._syntax~3f%29%29" class="RktValLink" data-pltdoc="x">syntax?</a></span></td></tr></table></blockquote></div><div class="SIntrapara">Applies the renamings of <span class="RktVar">intdef-ctx</span> to <span class="RktVar">stx</span>.</div></p><p><div class="SIntrapara"><blockquote class="SVInsetFlow"><table cellspacing="0" cellpadding="0" class="boxed RBoxed"><tr><td><blockquote class="SubFlow"><div class="RBackgroundLabel SIEHidden"><div class="RBackgroundLabelInner"><p>procedure</p></div></div><p class="RForeground"><span class="RktPn">(</span><a name="(def._((lib._racket/syntax..rkt)._syntax-local-eval))"></a><span title="Provided from: racket/syntax | Package: base"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._syntax-local-eval%29%29" class="RktValDef RktValLink" data-pltdoc="x">syntax-local-eval</a></span></span><span class="hspace">&nbsp;</span><span class="RktVar">stx</span><span class="hspace">&nbsp;</span>[<span class="RktVar">intdef-ctx</span>]<span class="RktPn">)</span><span class="hspace">&nbsp;</span>&rarr;<span class="hspace">&nbsp;</span><span class="RktSym"><a href="data-structure-contracts.html#%28form._%28%28lib._racket%2Fcontract%2Fprivate%2Fmisc..rkt%29._any%29%29" class="RktStxLink" data-pltdoc="x">any</a></span></p></blockquote></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">stx</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktSym"><a href="stxops.html#%28def._%28%28quote._~23~25kernel%29._syntax~3f%29%29" class="RktValLink" data-pltdoc="x">syntax?</a></span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">intdef-ctx</span><span class="hspace">&nbsp;</span>:<span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="data-structure-contracts.html#%28def._%28%28lib._racket%2Fcontract%2Fbase..rkt%29._or%2Fc%29%29" class="RktValLink" data-pltdoc="x">or/c</a></span><span class="hspace">&nbsp;</span><span class="RktSym"><a href="stxtrans.html#%28def._%28%28quote._~23~25kernel%29._internal-definition-context~3f%29%29" class="RktValLink" data-pltdoc="x">internal-definition-context?</a></span><span class="hspace">&nbsp;</span><span class="RktVal">#f</span><span class="RktPn">)</span><span class="hspace">&nbsp;</span>=<span class="hspace">&nbsp;</span><span class="RktVal">#f</span></td></tr></table></blockquote></div><div class="SIntrapara">Evaluates <span class="RktVar">stx</span> as an expression in the current transformer
environment (that is, at phase level 1), optionally extended with
<span class="RktVar">intdef-ctx</span>.</div></p><p><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><p>Examples:</p></td></tr><tr><td><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="stt">&gt; </span><span class="RktPn">(</span><span class="RktSym"><a href="define.html#%28form._%28%28lib._racket%2Fprivate%2Fbase..rkt%29._define-syntax%29%29" class="RktStxLink" data-pltdoc="x">define-syntax</a></span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym">show-me</span><span class="hspace">&nbsp;</span><span class="RktVar">stx</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="hspace">&nbsp;&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="stx-patterns.html#%28form._%28%28lib._racket%2Fprivate%2Fstxcase-scheme..rkt%29._syntax-case%29%29" class="RktStxLink" data-pltdoc="x">syntax-case</a></span><span class="hspace">&nbsp;</span><span class="RktVar">stx</span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="hspace">&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="RktPn">[</span><span class="RktPn">(</span><span class="RktSym">show-me</span><span class="hspace">&nbsp;</span><span class="RktSym">expr</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="hspace">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="begin.html#%28form._%28%28quote._~23~25kernel%29._begin%29%29" class="RktStxLink" data-pltdoc="x">begin</a></span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="hspace">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="Writing.html#%28def._%28%28quote._~23~25kernel%29._printf%29%29" class="RktValLink" data-pltdoc="x">printf</a></span><span class="hspace">&nbsp;</span><span class="RktVal">"at compile time produces ~s\n"</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="hspace">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fsyntax..rkt%29._syntax-local-eval%29%29" class="RktValLink" data-pltdoc="x">syntax-local-eval</a></span><span class="hspace">&nbsp;</span><span class="RktRdr">#'</span><span class="RktSym">expr</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="hspace">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="RktRdr">#'</span><span class="RktPn">(</span><span class="RktSym"><a href="Writing.html#%28def._%28%28quote._~23~25kernel%29._printf%29%29" class="RktValLink" data-pltdoc="x">printf</a></span><span class="hspace">&nbsp;</span><span class="RktVal">"at run time produces ~s\n"</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="hspace">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="RktSym">expr</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr></table></td></tr><tr><td><table cellspacing="0" cellpadding="0"><tr><td></td></tr></table></td></tr><tr><td><span class="stt">&gt; </span><span class="RktPn">(</span><span class="RktSym">show-me</span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="generic-numbers.html#%28def._%28%28quote._~23~25kernel%29._%2B%29%29" class="RktValLink" data-pltdoc="x">+</a></span><span class="hspace">&nbsp;</span><span class="RktVal">2</span><span class="hspace">&nbsp;</span><span class="RktVal">5</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><table cellspacing="0" cellpadding="0"><tr><td><p><span class="RktOut">at compile time produces 7</span></p></td></tr><tr><td><p><span class="RktOut">at run time produces 7</span></p></td></tr></table></td></tr><tr><td><table cellspacing="0" cellpadding="0"><tr><td></td></tr></table></td></tr><tr><td><span class="stt">&gt; </span><span class="RktPn">(</span><span class="RktSym"><a href="define.html#%28form._%28%28lib._racket%2Fprivate%2Fbase..rkt%29._define-for-syntax%29%29" class="RktStxLink" data-pltdoc="x">define-for-syntax</a></span><span class="hspace">&nbsp;</span><span class="RktSym">fruit</span><span class="hspace">&nbsp;</span><span class="RktVal">'</span><span class="RktVal">apple</span><span class="RktPn">)</span></td></tr><tr><td><table cellspacing="0" cellpadding="0"><tr><td></td></tr></table></td></tr><tr><td><span class="stt">&gt; </span><span class="RktPn">(</span><span class="RktSym"><a href="define.html#%28form._%28%28lib._racket%2Fprivate%2Fbase..rkt%29._define%29%29" class="RktStxLink" data-pltdoc="x">define</a></span><span class="hspace">&nbsp;</span><span class="RktSym">fruit</span><span class="hspace">&nbsp;</span><span class="RktVal">'</span><span class="RktVal">pear</span><span class="RktPn">)</span></td></tr><tr><td><table cellspacing="0" cellpadding="0"><tr><td></td></tr></table></td></tr><tr><td><span class="stt">&gt; </span><span class="RktPn">(</span><span class="RktSym">show-me</span><span class="hspace">&nbsp;</span><span class="RktSym">fruit</span><span class="RktPn">)</span></td></tr><tr><td><table cellspacing="0" cellpadding="0"><tr><td><p><span class="RktOut">at compile time produces apple</span></p></td></tr><tr><td><p><span class="RktOut">at run time produces pear</span></p></td></tr></table></td></tr><tr><td><table cellspacing="0" cellpadding="0"><tr><td></td></tr></table></td></tr></table></blockquote></td></tr></table></p><p><div class="SIntrapara"><blockquote class="SVInsetFlow"><table cellspacing="0" cellpadding="0" class="boxed RBoxed"><tr><td><blockquote class="SubFlow"><div class="RBackgroundLabel SIEHidden"><div class="RBackgroundLabelInner"><p>syntax</p></div></div><table cellspacing="0" cellpadding="0" class="RktBlk RForeground"><tr><td><span class="RktPn">(</span><a name="(form._((lib._racket/syntax..rkt)._with-syntax*))"></a><span title="Provided from: racket/syntax | Package: base"><span class="RktSym"><a href="#%28form._%28%28lib._racket%2Fsyntax..rkt%29._with-syntax%2A%29%29" class="RktStxDef RktStxLink" data-pltdoc="x">with-syntax*</a></span></span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktPn">[</span><span class="RktVar">pattern</span><span class="hspace">&nbsp;</span><span class="RktVar">stx-expr</span><span class="RktPn">]</span><span class="hspace">&nbsp;</span><span class="RktMeta">...</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="RktVar">body</span><span class="hspace">&nbsp;</span><span class="RktMeta">...+</span><span class="RktPn">)</span></td></tr></table></blockquote></td></tr><tr><td><span class="stt">&nbsp;</span></td></tr><tr><td><table cellspacing="0" cellpadding="0" class="argcontract"><tr><td><span class="hspace">&nbsp;&nbsp;</span></td><td><span class="RktVar">stx-expr</span></td><td><span class="hspace">&nbsp;</span></td><td>:</td><td><span class="hspace">&nbsp;</span></td><td><span class="RktSym"><a href="stxops.html#%28def._%28%28quote._~23~25kernel%29._syntax~3f%29%29" class="RktValLink" data-pltdoc="x">syntax?</a></span></td></tr></table></td></tr></table></blockquote></div><div class="SIntrapara">Similar to <span class="RktSym"><a href="stx-patterns.html#%28form._%28%28lib._racket%2Fprivate%2Fstxcase-scheme..rkt%29._with-syntax%29%29" class="RktStxLink" data-pltdoc="x">with-syntax</a></span>, but the pattern variables of each
<span class="RktVar">pattern</span> are bound in the <span class="RktVar">stx-expr</span>s of subsequent
clauses as well as the <span class="RktVar">body</span>s, and the <span class="RktVar">pattern</span>s need
not bind distinct pattern variables; later bindings shadow earlier
bindings.</div></p><p><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><p>Example:</p></td></tr><tr><td><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="stt">&gt; </span><span class="RktPn">(</span><span class="RktSym"><a href="#%28form._%28%28lib._racket%2Fsyntax..rkt%29._with-syntax%2A%29%29" class="RktStxLink" data-pltdoc="x">with-syntax*</a></span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktPn">[</span><span class="RktPn">(</span><span class="RktSym">x</span><span class="hspace">&nbsp;</span><span class="RktSym">y</span><span class="RktPn">)</span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym"><a href="pairs.html#%28def._%28%28quote._~23~25kernel%29._list%29%29" class="RktValLink" data-pltdoc="x">list</a></span><span class="hspace">&nbsp;</span><span class="RktRdr">#'</span><span class="RktSym">val1</span><span class="hspace">&nbsp;</span><span class="RktRdr">#'</span><span class="RktSym">val2</span><span class="RktPn">)</span><span class="RktPn">]</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="hspace">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="RktPn">[</span><span class="RktSym">nest</span><span class="hspace">&nbsp;</span><span class="RktRdr">#'</span><span class="RktPn">(</span><span class="RktPn">(</span><span class="RktSym">x</span><span class="RktPn">)</span><span class="hspace">&nbsp;</span><span class="RktPn">(</span><span class="RktSym">y</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace">&nbsp;&nbsp;</span><span class="hspace">&nbsp;&nbsp;</span><span class="RktRdr">#'</span><span class="RktSym">nest</span><span class="RktPn">)</span></td></tr></table></td></tr><tr><td><p><span class="RktRes">#&lt;syntax:21:0 ((val1) (val2))&gt;</span></p></td></tr></table></blockquote></td></tr></table></p><div class="navsetbottom"><span class="navleft"><form class="searchform"><input class="searchbox" style="color: #888;" type="text" value="...search manuals..." title="Enter a search string to search the manuals" onkeypress="return DoSearchKey(event, this, &quot;6.1&quot;, &quot;../&quot;);" onfocus="this.style.color=&quot;black&quot;; this.style.textAlign=&quot;left&quot;; if (this.value == &quot;...search manuals...&quot;) this.value=&quot;&quot;;" onblur="if (this.value.match(/^ *$/)) { this.style.color=&quot;#888&quot;; this.style.textAlign=&quot;center&quot;; this.value=&quot;...search manuals...&quot;; }"/></form>&nbsp;&nbsp;<a href="../index.html" title="up to the documentation top" data-pltdoc="x" onclick="return GotoPLTRoot(&quot;6.1&quot;);">top</a></span><span class="navright">&nbsp;&nbsp;<a href="include.html" title="backward to &quot;12.10 File Inclusion&quot;" data-pltdoc="x">&larr; prev</a>&nbsp;&nbsp;<a href="Macros.html" title="up to &quot;12 Macros&quot;" data-pltdoc="x">up</a>&nbsp;&nbsp;<a href="input-and-output.html" title="forward to &quot;13 Input and Output&quot;" data-pltdoc="x">next &rarr;</a></span>&nbsp;</div></div></div><div id="contextindicator">&nbsp;</div></body></html>