/usr/share/doc/racket/option-contract/index.html is in racket-doc 6.7-3.
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 | <!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>Option Contracts</title><link rel="stylesheet" type="text/css" href="../scribble.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;">•</td><td></td><td><a href="" class="tocviewselflink" data-pltdoc="x">Option Contracts</a></td></tr></table></div></div></div><div class="tocsub"><table class="tocsublist" cellspacing="0"><tr><td><span class="tocsublinknumber"></span><a href="#%28part._top%29" class="tocsubseclink" data-pltdoc="x">Option Contracts</a></td></tr><tr><td><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">option/<span class="mywbr"> </span>c</span></span></a></td></tr><tr><td><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._exercise-option%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">exercise-<wbr></wbr>option</span></span></a></td></tr><tr><td><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._transfer%2Fc%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">transfer/<span class="mywbr"> </span>c</span></span></a></td></tr><tr><td><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._waive-option%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">waive-<wbr></wbr>option</span></span></a></td></tr><tr><td><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._tweak-option%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">tweak-<wbr></wbr>option</span></span></a></td></tr><tr><td><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._has-option~3f%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">has-<wbr></wbr>option?</span></span></a></td></tr><tr><td><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._has-option-with-contract~3f%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">has-<wbr></wbr>option-<wbr></wbr>with-<wbr></wbr>contract?</span></span></a></td></tr><tr><td><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._invariant%2Fc%29%29" class="tocsubnonseclink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">invariant/<span class="mywbr"> </span>c</span></span></a></td></tr></table></div></div><div class="maincolumn"><div class="main"><div class="versionbox"><span class="version">6.7</span></div><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, "6.7", "../");" onfocus="this.style.color="black"; this.style.textAlign="left"; if (this.value == "...search manuals...") this.value="";" onblur="if (this.value.match(/^ *$/)) { this.style.color="#888"; this.style.textAlign="center"; this.value="...search manuals..."; }"/></form> <a href="../index.html" title="up to the documentation top" data-pltdoc="x" onclick="return GotoPLTRoot("6.7");">top</a></span><span class="navright"> <span class="nonavigation">← prev</span> <a href="../index.html" title="up to the documentation top" data-pltdoc="x" onclick="return GotoPLTRoot("6.7");">up</a> <span class="nonavigation">next →</span></span> </div><h2 x-source-module="(lib "scribblings/option-contract.scrbl")" x-source-pkg="option-contract-doc" x-part-tag=""top""><a name="(part._top)"></a><a name="(part._options)"></a><a name="(mod-path._racket/contract/option)"></a>Option Contracts</h2><p><table cellspacing="0" cellpadding="0" class="defmodule"><tr><td align="left" colspan="2"><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=require.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._require%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">require</a></span><span class="stt"> </span><a href="" class="RktModLink" data-pltdoc="x"><span class="RktSym">racket/contract/option</span></a><span class="RktPn">)</span></td></tr><tr><td align="left"> </td><td align="right"><span class="RpackageSpec"><span class="Smaller"> package:</span> <span class="stt">option-contract-lib</span></span></td></tr></table></p><p>This module introduces <span style="font-style: italic">option contracts</span>, a flavor of behavioral
software contracts. With option contracts developers control in a
programmatic manner whether, when, and how often contracts are
checked. Using this flavor of contracts, Racketeers can mimic any compiler
flag system but also create run-time informed checking systems.</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 valign="top"><span class="RktPn">(</span><a name="(def._((lib._racket/contract/option..rkt)._option/c))"></a><span title="Provided from: racket/contract/option | Package: option-contract-lib"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValDef RktValLink" data-pltdoc="x">option/c</a></span></span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="RktVar">c</span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td></tr><tr><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span>[</td><td valign="top"><span class="RktPn">#:with-contract</span><span class="hspace"> </span><span class="RktVar">with</span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td></tr><tr><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="RktPn">#:tester</span><span class="hspace"> </span><span class="RktVar">tester</span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td></tr><tr><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="RktPn">#:invariant</span><span class="hspace"> </span><span class="RktVar">invariant</span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td></tr><tr><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="RktPn">#:immutable</span><span class="hspace"> </span><span class="RktVar">immutable</span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td></tr><tr><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="RktPn">#:flat?</span><span class="hspace"> </span><span class="RktVar">flat?</span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td></tr><tr><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="RktPn">#:struct</span><span class="hspace"> </span><span class="RktVar">struct-id</span>]<span class="RktPn">)</span></td><td valign="top"><span class="hspace"> </span></td><td valign="top">→</td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=contract-utilities.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fguts..rkt%2529._contract%7E3f%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">contract?</a></span></td></tr></table></blockquote></td></tr><tr><td><span class="hspace"> </span><span class="RktVar">c</span><span class="hspace"> </span>:<span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=contract-utilities.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fguts..rkt%2529._contract%7E3f%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">contract?</a></span></td></tr><tr><td><span class="hspace"> </span><span class="RktVar">with</span><span class="hspace"> </span>:<span class="hspace"> </span><span class="RktSym">boolean?</span><span class="hspace"> </span>=<span class="hspace"> </span><span class="RktVal">#f</span></td></tr><tr><td><span class="hspace"> </span><span class="RktVar">tester</span><span class="hspace"> </span>:<span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._or%252Fc%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">or/c</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=function-contracts.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._-%7E3e%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x"><span class="nobreak">-></span></a></span><span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fmisc..rkt%2529._any%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">any</a></span><span class="hspace"> </span><span class="RktSym">boolean?</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">dont-care</span><span class="RktPn">)</span><span class="hspace"> </span>=<span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">dont-care</span></td></tr><tr><td><span class="hspace"> </span><span class="RktVar">invariant</span><span class="hspace"> </span>:<span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._or%252Fc%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">or/c</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=function-contracts.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._-%7E3e%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x"><span class="nobreak">-></span></a></span><span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fmisc..rkt%2529._any%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">any</a></span><span class="hspace"> </span><span class="RktSym">boolean?</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">dont-care</span><span class="RktPn">)</span><span class="hspace"> </span>=<span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">dont-care</span></td></tr><tr><td><span class="hspace"> </span><span class="RktVar">immutable</span><span class="hspace"> </span>:<span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._or%252Fc%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">or/c</a></span><span class="hspace"> </span><span class="RktVal">#t</span><span class="hspace"> </span><span class="RktVal">#f</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">dont-care</span><span class="RktPn">)</span><span class="hspace"> </span>=<span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">dont-care</span></td></tr><tr><td><span class="hspace"> </span><span class="RktVar">flat?</span><span class="hspace"> </span>:<span class="hspace"> </span><span class="RktSym">boolean?</span><span class="hspace"> </span>=<span class="hspace"> </span><span class="RktVal">#f</span></td></tr><tr><td><span class="hspace"> </span><span class="RktVar">struct-id</span><span class="hspace"> </span>:<span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._or%252Fc%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">or/c</a></span><span class="hspace"> </span><span class="RktSym">identifier?</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">none</span><span class="RktPn">)</span><span class="hspace"> </span>=<span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">none</span></td></tr></table></blockquote></div><div class="SIntrapara">Returns a contract that recognizes vectors or hashes or instances of
struct <span class="RktVar">struct-id</span>. The data structure must match <span class="RktVar">c</span> and pass the
<span class="RktVar">tester</span>.</div></p><p>When an <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span> contract is attached to a value, the value is checked against the
<span class="RktVar">tester</span>, if <span class="RktVar">tester</span> is a predicate. After that,
contract checking is disabled for the value, if <span class="RktVar">with</span> is <span class="RktVal">#f</span>. If <span class="RktVar">with</span>
is <span class="RktVal">#t</span> contract checking for the value remains enabled for <span class="RktVar">c</span>.</p><p>If <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._waive-option%29%29" class="RktValLink" data-pltdoc="x">waive-option</a></span> is applied to a value guarded by an <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span>
contract, then <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._waive-option%29%29" class="RktValLink" data-pltdoc="x">waive-option</a></span> returns the value after removing the <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span> guard.
If <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._exercise-option%29%29" class="RktValLink" data-pltdoc="x">exercise-option</a></span> is applied to a value guarded by an <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span>
contract, then <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._exercise-option%29%29" class="RktValLink" data-pltdoc="x">exercise-option</a></span> returns the value with contract checking
enabled for <span class="RktVar">c</span>. If the <span class="RktVar">invariant</span> argument is a predicate, then
<span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._exercise-option%29%29" class="RktValLink" data-pltdoc="x">exercise-option</a></span> returns the value with contract checking enabled for
<span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._invariant%2Fc%29%29" class="RktValLink" data-pltdoc="x">invariant/c</a></span><span class="stt"> </span><span class="RktVar">c</span><span class="stt"> </span><span class="RktVar">invariant</span><span class="stt"> </span><span class="RktPn">#:immutable</span><span class="stt"> </span><span class="RktVar">immutable</span><span class="stt"> </span><span class="RktPn">#:flat?</span><span class="stt"> </span><span class="RktVar">flat?</span><span class="stt"> </span><span class="RktPn">#:struct</span><span class="stt"> </span><span class="RktVar">struct-id</span><span class="RktPn">)</span>.</p><p>The arguments <span class="RktVar">flat?</span> and <span class="RktVar">immutable</span> should be provided only if <span class="RktVar">invariant</span>
is a predicate. In any other case, the result is a contract error.</p><p><div class="SIntrapara">Examples:</div><div class="SIntrapara"><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">module</span><span class="hspace"> </span><span class="RktSym">server0</span><span class="hspace"> </span><span class="RktSym">racket</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">require</span><span class="hspace"> </span><span class="RktSym">racket/contract/option</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">provide</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=attaching-contracts-to-values.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._contract-out%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">contract-out</a></span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">vec</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fvector..rkt%2529._vectorof%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">vectorof</a></span><span class="hspace"> </span><span class="RktSym">number?</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">define</span><span class="hspace"> </span><span class="RktSym">vec</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">vector</span><span class="hspace"> </span><span class="RktVal">1</span><span class="hspace"> </span><span class="RktVal">2</span><span class="hspace"> </span><span class="RktVal">3</span><span class="hspace"> </span><span class="RktVal">4</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr></table></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">require</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">server0</span><span class="RktPn">)</span></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">vector-set!</span><span class="hspace"> </span><span class="RktSym">vec</span><span class="hspace"> </span><span class="RktVal">1</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">foo</span><span class="RktPn">)</span></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">vector-ref</span><span class="hspace"> </span><span class="RktSym">vec</span><span class="hspace"> </span><span class="RktVal">1</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktRes">'foo</span></p></td></tr><tr><td><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">module</span><span class="hspace"> </span><span class="RktSym">server1</span><span class="hspace"> </span><span class="RktSym">racket</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">require</span><span class="hspace"> </span><span class="RktSym">racket/contract/option</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">provide</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=attaching-contracts-to-values.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._contract-out%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">contract-out</a></span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">vec</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fvector..rkt%2529._vectorof%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">vectorof</a></span><span class="hspace"> </span><span class="RktSym">number?</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktPn">#:with-contract</span><span class="hspace"> </span><span class="RktVal">#t</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">define</span><span class="hspace"> </span><span class="RktSym">vec</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">vector</span><span class="hspace"> </span><span class="RktVal">1</span><span class="hspace"> </span><span class="RktVal">2</span><span class="hspace"> </span><span class="RktVal">3</span><span class="hspace"> </span><span class="RktVal">4</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr></table></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">require</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">server1</span><span class="RktPn">)</span></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">vector-set!</span><span class="hspace"> </span><span class="RktSym">vec</span><span class="hspace"> </span><span class="RktVal">1</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">foo</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktErr">vec: contract violation</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">expected: number?</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">given: 'foo</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">in: an element of</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">the option of</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">(option/c</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">(vectorof number?)</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">#:with-contract</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">#t)</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">contract from: server1</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">blaming: top-level</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">(assuming the contract is correct)</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">at: eval:6.0</span></p></td></tr><tr><td><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">module</span><span class="hspace"> </span><span class="RktSym">server2</span><span class="hspace"> </span><span class="RktSym">racket</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">require</span><span class="hspace"> </span><span class="RktSym">racket/contract/option</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">provide</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=attaching-contracts-to-values.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._contract-out%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">contract-out</a></span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">vec</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fvector..rkt%2529._vectorof%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">vectorof</a></span><span class="hspace"> </span><span class="RktSym">number?</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktPn">#:tester</span><span class="hspace"> </span><span class="RktSym">sorted?</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">define</span><span class="hspace"> </span><span class="RktSym">vec</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">vector</span><span class="hspace"> </span><span class="RktVal">1</span><span class="hspace"> </span><span class="RktVal">42</span><span class="hspace"> </span><span class="RktVal">3</span><span class="hspace"> </span><span class="RktVal">4</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">define</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">sorted?</span><span class="hspace"> </span><span class="RktSym">vec</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">for/and</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktPn">[</span><span class="RktSym">el</span><span class="hspace"> </span><span class="RktSym">vec</span><span class="RktPn">]</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">cel</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">vector-drop</span><span class="hspace"> </span><span class="RktSym">vec</span><span class="hspace"> </span><span class="RktVal">1</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><=</span><span class="hspace"> </span><span class="RktSym">el</span><span class="hspace"> </span><span class="RktSym">cel</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr></table></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">require</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">server2</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktErr">vec: broke its own contract;</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">in: option contract tester #<procedure:sorted?> of</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">(option/c</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">(vectorof number?)</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">#:tester</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">#<procedure:sorted?>)</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">contract from: server2</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">blaming: server2</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">(assuming the contract is correct)</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">at: eval:9.0</span></p></td></tr></table></blockquote></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/contract/option..rkt)._exercise-option))"></a><span title="Provided from: racket/contract/option | Package: option-contract-lib"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._exercise-option%29%29" class="RktValDef RktValLink" data-pltdoc="x">exercise-option</a></span></span><span class="hspace"> </span><span class="RktVar">x</span><span class="RktPn">)</span><span class="hspace"> </span>→<span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fmisc..rkt%2529._any%252Fc%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">any/c</a></span></p></blockquote></td></tr><tr><td><span class="hspace"> </span><span class="RktVar">x</span><span class="hspace"> </span>:<span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fmisc..rkt%2529._any%252Fc%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">any/c</a></span></td></tr></table></blockquote></div><div class="SIntrapara">Returns <span class="RktVar">x</span> with contract checking enabled if an <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span> guards
<span class="RktVar">x</span>. In any other case it returns <span class="RktVar">x</span>. The result of <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._exercise-option%29%29" class="RktValLink" data-pltdoc="x">exercise-option</a></span>
loses the guard related to <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span>, if it has one to begin with, and thus its contract checking status cannot change further.</div></p><p><div class="SIntrapara">Examples:</div><div class="SIntrapara"><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">module</span><span class="hspace"> </span><span class="RktSym">server3</span><span class="hspace"> </span><span class="RktSym">racket</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">require</span><span class="hspace"> </span><span class="RktSym">racket/contract/option</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">provide</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=attaching-contracts-to-values.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._contract-out%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">contract-out</a></span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">foo</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=function-contracts.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._-%7E3e%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x"><span class="nobreak">-></span></a></span><span class="hspace"> </span><span class="RktSym">number?</span><span class="hspace"> </span><span class="RktSym">symbol?</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">define</span><span class="hspace"> </span><span class="RktSym">foo</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">λ</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktVar">x</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktVar">x</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr></table></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">require</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">server3</span><span class="hspace"> </span><span class="RktSym">racket/contract/option</span><span class="RktPn">)</span></td></tr><tr><td><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym">define</span><span class="hspace"> </span><span class="RktSym">e-foo</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._exercise-option%29%29" class="RktValLink" data-pltdoc="x">exercise-option</a></span><span class="hspace"> </span><span class="RktSym">foo</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td> </td></tr></table></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">foo</span><span class="hspace"> </span><span class="RktVal">42</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktRes">42</span></p></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">e-foo</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">wrong</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktErr">foo: contract violation</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">expected: number?</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">given: 'wrong</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">in: the 1st argument of</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">the option of</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">(option/c (-> number? symbol?))</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">contract from: server3</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">blaming: top-level</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">(assuming the contract is correct)</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">at: eval:11.0</span></p></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._exercise-option%29%29" class="RktValLink" data-pltdoc="x">exercise-option</a></span><span class="hspace"> </span><span class="RktSym">e-foo</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">wrong</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktErr">foo: contract violation</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">expected: number?</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">given: 'wrong</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">in: the 1st argument of</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">the option of</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">(option/c (-> number? symbol?))</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">contract from: server3</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">blaming: top-level</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">(assuming the contract is correct)</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">at: eval:11.0</span></p></td></tr></table></blockquote></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>value</p></div></div><p class="RForeground"><a name="(def._((lib._racket/contract/option..rkt)._transfer/c))"></a><span title="Provided from: racket/contract/option | Package: option-contract-lib"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._transfer%2Fc%29%29" class="RktValDef RktValLink" data-pltdoc="x">transfer/c</a></span></span><span class="hspace"> </span>:<span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=contract-utilities.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fguts..rkt%2529._contract%7E3f%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">contract?</a></span></p></blockquote></td></tr></table></blockquote></div><div class="SIntrapara">A contract that accepts any value. If the value is guarded with an
<span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span> contract, <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._transfer%2Fc%29%29" class="RktValLink" data-pltdoc="x">transfer/c</a></span> modifies the blame
information for the <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span> contract by adding the providing module and its client
to the positive and negative blame parties respectively. If the value is not a value guarded with an
<span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span> contract, then <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._transfer%2Fc%29%29" class="RktValLink" data-pltdoc="x">transfer/c</a></span> is equivalent to <span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fmisc..rkt%2529._any%252Fc%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">any/c</a></span>.</div></p><p><div class="SIntrapara">Examples:</div><div class="SIntrapara"><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">module</span><span class="hspace"> </span><span class="RktSym">server4</span><span class="hspace"> </span><span class="RktSym">racket</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">require</span><span class="hspace"> </span><span class="RktSym">racket/contract/option</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">provide</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=attaching-contracts-to-values.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._contract-out%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">contract-out</a></span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">foo</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=function-contracts.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._-%7E3e%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x"><span class="nobreak">-></span></a></span><span class="hspace"> </span><span class="RktSym">number?</span><span class="hspace"> </span><span class="RktSym">symbol?</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">define</span><span class="hspace"> </span><span class="RktSym">foo</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">λ</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">x</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktSym">x</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" class="RktBlk"><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">module</span><span class="hspace"> </span><span class="RktSym">middleman</span><span class="hspace"> </span><span class="RktSym">racket</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">require</span><span class="hspace"> </span><span class="RktSym">racket/contract/option</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">server4</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">provide</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=attaching-contracts-to-values.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._contract-out%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">contract-out</a></span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">foo</span><span class="hspace"> </span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._transfer%2Fc%29%29" class="RktValLink" data-pltdoc="x">transfer/c</a></span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr></table></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">require</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">middleman</span><span class="hspace"> </span><span class="RktSym">racket/contract/option</span><span class="RktPn">)</span></td></tr><tr><td><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym">define</span><span class="hspace"> </span><span class="RktSym">e-foo</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._exercise-option%29%29" class="RktValLink" data-pltdoc="x">exercise-option</a></span><span class="hspace"> </span><span class="RktSym">foo</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td> </td></tr></table></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">e-foo</span><span class="hspace"> </span><span class="RktVal">1</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktErr">foo: broke its own contract</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">promised: symbol?</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">produced: 1</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">in: the range of</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">the option of</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">(option/c (-> number? symbol?))</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">contract from: server4</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">blaming multiple parties:</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">middleman</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">server4</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">(assuming the contract is correct)</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">at: eval:17.0</span></p></td></tr><tr><td><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">module</span><span class="hspace"> </span><span class="RktSym">server5</span><span class="hspace"> </span><span class="RktSym">racket</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">require</span><span class="hspace"> </span><span class="RktSym">racket/contract/option</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">provide</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=attaching-contracts-to-values.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._contract-out%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">contract-out</a></span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">boo</span><span class="hspace"> </span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._transfer%2Fc%29%29" class="RktValLink" data-pltdoc="x">transfer/c</a></span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">define</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">boo</span><span class="hspace"> </span><span class="RktSym">x</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktSym">x</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr></table></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">require</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">server5</span><span class="RktPn">)</span></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">boo</span><span class="hspace"> </span><span class="RktVal">42</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktRes">42</span></p></td></tr></table></blockquote></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/contract/option..rkt)._waive-option))"></a><span title="Provided from: racket/contract/option | Package: option-contract-lib"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._waive-option%29%29" class="RktValDef RktValLink" data-pltdoc="x">waive-option</a></span></span><span class="hspace"> </span><span class="RktVar">x</span><span class="RktPn">)</span><span class="hspace"> </span>→<span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fmisc..rkt%2529._any%252Fc%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">any/c</a></span></p></blockquote></td></tr><tr><td><span class="hspace"> </span><span class="RktVar">x</span><span class="hspace"> </span>:<span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fmisc..rkt%2529._any%252Fc%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">any/c</a></span></td></tr></table></blockquote></div><div class="SIntrapara">If an <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span> guards <span class="RktVar">x</span>, then <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._waive-option%29%29" class="RktValLink" data-pltdoc="x">waive-option</a></span> returns
<span class="RktVar">x</span> without the <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span> guard.
In any other case it returns <span class="RktVar">x</span>. The result of <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._waive-option%29%29" class="RktValLink" data-pltdoc="x">waive-option</a></span>
loses the guard related to <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span>, if it had one to begin with, and thus its contract checking status cannot change further.</div></p><p><div class="SIntrapara">Examples:</div><div class="SIntrapara"><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">module</span><span class="hspace"> </span><span class="RktSym">server6</span><span class="hspace"> </span><span class="RktSym">racket</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">require</span><span class="hspace"> </span><span class="RktSym">racket/contract/option</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">provide</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=attaching-contracts-to-values.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._contract-out%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">contract-out</a></span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">bar</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=function-contracts.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._-%7E3e%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x"><span class="nobreak">-></span></a></span><span class="hspace"> </span><span class="RktSym">number?</span><span class="hspace"> </span><span class="RktSym">symbol?</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">define</span><span class="hspace"> </span><span class="RktSym">bar</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">λ</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktVar">x</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktVar">x</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr></table></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">require</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">server6</span><span class="hspace"> </span><span class="RktSym">racket/contract/option</span><span class="RktPn">)</span></td></tr><tr><td><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym">define</span><span class="hspace"> </span><span class="RktSym">e-bar</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._waive-option%29%29" class="RktValLink" data-pltdoc="x">waive-option</a></span><span class="hspace"> </span><span class="RktSym">bar</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td> </td></tr></table></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">e-bar</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">wrong</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktRes">'wrong</span></p></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._waive-option%29%29" class="RktValLink" data-pltdoc="x">waive-option</a></span><span class="hspace"> </span><span class="RktSym">e-bar</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">wrong</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktRes">'wrong</span></p></td></tr></table></blockquote></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/contract/option..rkt)._tweak-option))"></a><span title="Provided from: racket/contract/option | Package: option-contract-lib"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._tweak-option%29%29" class="RktValDef RktValLink" data-pltdoc="x">tweak-option</a></span></span><span class="hspace"> </span><span class="RktVar">x</span><span class="RktPn">)</span><span class="hspace"> </span>→<span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fmisc..rkt%2529._any%252Fc%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">any/c</a></span></p></blockquote></td></tr><tr><td><span class="hspace"> </span><span class="RktVar">x</span><span class="hspace"> </span>:<span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fmisc..rkt%2529._any%252Fc%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">any/c</a></span></td></tr></table></blockquote></div><div class="SIntrapara">If an <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span> guards <span class="RktVar">x</span> and contract checking for <span class="RktVar">x</span> is enabled,
then <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._tweak-option%29%29" class="RktValLink" data-pltdoc="x">tweak-option</a></span> returns
<span class="RktVar">x</span> with contract checking for <span class="RktVar">x</span> disabled.
If an <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span> guards <span class="RktVar">x</span> and contract checking for <span class="RktVar">x</span> is disabled,
then <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._tweak-option%29%29" class="RktValLink" data-pltdoc="x">tweak-option</a></span> returns
<span class="RktVar">x</span> with contract checking for <span class="RktVar">x</span> enabled.
In any other case it returns <span class="RktVar">x</span>. The result of <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._tweak-option%29%29" class="RktValLink" data-pltdoc="x">tweak-option</a></span>
retains the guard related to <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span> if it has one to begin with and thus its contract checking status can change further
using <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._tweak-option%29%29" class="RktValLink" data-pltdoc="x">tweak-option</a></span>, <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._exercise-option%29%29" class="RktValLink" data-pltdoc="x">exercise-option</a></span> or <span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._waive-option%29%29" class="RktValLink" data-pltdoc="x">waive-option</a></span>.</div></p><p><div class="SIntrapara">Examples:</div><div class="SIntrapara"><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">module</span><span class="hspace"> </span><span class="RktSym">server7</span><span class="hspace"> </span><span class="RktSym">racket</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">require</span><span class="hspace"> </span><span class="RktSym">racket/contract/option</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">provide</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=attaching-contracts-to-values.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._contract-out%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">contract-out</a></span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">bar</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._option%2Fc%29%29" class="RktValLink" data-pltdoc="x">option/c</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=function-contracts.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._-%7E3e%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x"><span class="nobreak">-></span></a></span><span class="hspace"> </span><span class="RktSym">number?</span><span class="hspace"> </span><span class="RktSym">symbol?</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">define</span><span class="hspace"> </span><span class="RktSym">bar</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">λ</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktVar">x</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktVar">x</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr></table></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">require</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">server7</span><span class="hspace"> </span><span class="RktSym">racket/contract/option</span><span class="RktPn">)</span></td></tr><tr><td><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym">define</span><span class="hspace"> </span><span class="RktSym">t-bar</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._tweak-option%29%29" class="RktValLink" data-pltdoc="x">tweak-option</a></span><span class="hspace"> </span><span class="RktSym">bar</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td> </td></tr></table></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">t-bar</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">wrong</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktErr">bar: contract violation</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">expected: number?</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">given: 'wrong</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">in: the 1st argument of</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">the option of</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">(option/c (-> number? symbol?))</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">contract from: server7</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">blaming: top-level</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">(assuming the contract is correct)</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">at: eval:30.0</span></p></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._tweak-option%29%29" class="RktValLink" data-pltdoc="x">tweak-option</a></span><span class="hspace"> </span><span class="RktSym">t-bar</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">wrong</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktRes">'wrong</span></p></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._waive-option%29%29" class="RktValLink" data-pltdoc="x">waive-option</a></span><span class="hspace"> </span><span class="RktSym">t-bar</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">wrong</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktRes">'wrong</span></p></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._exercise-option%29%29" class="RktValLink" data-pltdoc="x">exercise-option</a></span><span class="hspace"> </span><span class="RktSym">t-bar</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">wrong</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktErr">bar: contract violation</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">expected: number?</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">given: 'wrong</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">in: the 1st argument of</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">the option of</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">(option/c (-> number? symbol?))</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">contract from: server7</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">blaming: top-level</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">(assuming the contract is correct)</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">at: eval:30.0</span></p></td></tr></table></blockquote></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/contract/option..rkt)._has-option~3f))"></a><span title="Provided from: racket/contract/option | Package: option-contract-lib"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._has-option~3f%29%29" class="RktValDef RktValLink" data-pltdoc="x">has-option?</a></span></span><span class="hspace"> </span><span class="RktVar">v</span><span class="RktPn">)</span><span class="hspace"> </span>→<span class="hspace"> </span><span class="RktSym">boolean?</span></p></blockquote></td></tr><tr><td><span class="hspace"> </span><span class="RktVar">v</span><span class="hspace"> </span>:<span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fmisc..rkt%2529._any%252Fc%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">any/c</a></span></td></tr></table></blockquote></div><div class="SIntrapara">Returns <span class="RktVal">#t</span> if <span class="RktVar">v</span> has an option contract.</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/contract/option..rkt)._has-option-with-contract~3f))"></a><span title="Provided from: racket/contract/option | Package: option-contract-lib"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._has-option-with-contract~3f%29%29" class="RktValDef RktValLink" data-pltdoc="x">has-option-with-contract?</a></span></span><span class="hspace"> </span><span class="RktVar">v</span><span class="RktPn">)</span><span class="hspace"> </span>→<span class="hspace"> </span><span class="RktSym">boolean?</span></p></blockquote></td></tr><tr><td><span class="hspace"> </span><span class="RktVar">v</span><span class="hspace"> </span>:<span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fmisc..rkt%2529._any%252Fc%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">any/c</a></span></td></tr></table></blockquote></div><div class="SIntrapara">Returns <span class="RktVal">#t</span> if <span class="RktVar">v</span> has an option contract with contract checking enabled.</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 valign="top"><span class="RktPn">(</span><a name="(def._((lib._racket/contract/option..rkt)._invariant/c))"></a><span title="Provided from: racket/contract/option | Package: option-contract-lib"><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._invariant%2Fc%29%29" class="RktValDef RktValLink" data-pltdoc="x">invariant/c</a></span></span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="RktVar">c</span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td></tr><tr><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="RktVar">invariant</span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td></tr><tr><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span>[</td><td valign="top"><span class="RktPn">#:immutable</span><span class="hspace"> </span><span class="RktVar">immutable</span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td></tr><tr><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="RktPn">#:flat?</span><span class="hspace"> </span><span class="RktVar">flat?</span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td></tr><tr><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="RktPn">#:struct</span><span class="hspace"> </span><span class="RktVar">struct-id</span>]<span class="RktPn">)</span></td><td valign="top"><span class="hspace"> </span></td><td valign="top">→</td><td valign="top"><span class="hspace"> </span></td><td valign="top"><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=contract-utilities.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fguts..rkt%2529._contract%7E3f%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">contract?</a></span></td></tr></table></blockquote></td></tr><tr><td><span class="hspace"> </span><span class="RktVar">c</span><span class="hspace"> </span>:<span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=contract-utilities.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fguts..rkt%2529._contract%7E3f%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">contract?</a></span></td></tr><tr><td><span class="hspace"> </span><span class="RktVar">invariant</span><span class="hspace"> </span>:<span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=function-contracts.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._-%7E3e%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x"><span class="nobreak">-></span></a></span><span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fmisc..rkt%2529._any%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">any</a></span><span class="hspace"> </span><span class="RktSym">boolean?</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktVar">immutable</span><span class="hspace"> </span>:<span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._or%252Fc%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">or/c</a></span><span class="hspace"> </span><span class="RktVal">#t</span><span class="hspace"> </span><span class="RktVal">#f</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">dont-care</span><span class="RktPn">)</span><span class="hspace"> </span>=<span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">dont-care</span></td></tr><tr><td><span class="hspace"> </span><span class="RktVar">flat?</span><span class="hspace"> </span>:<span class="hspace"> </span><span class="RktSym">boolean?</span><span class="hspace"> </span>=<span class="hspace"> </span><span class="RktVal">#f</span></td></tr><tr><td><span class="hspace"> </span><span class="RktVar">struct-id</span><span class="hspace"> </span>:<span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._or%252Fc%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">or/c</a></span><span class="hspace"> </span><span class="RktSym">identifier?</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">none</span><span class="RktPn">)</span><span class="hspace"> </span>=<span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">none</span></td></tr></table></blockquote></div><div class="SIntrapara">Returns a contract that recognizes vectors or hashes or instances of
struct <span class="RktVar">struct-id</span>. The data structure must match <span class="RktVar">c</span> and satisfy the
<span class="RktVar">invariant</span> argument.</div></p><p>If the <span class="RktVar">flat?</span> argument is <span class="RktVal">#t</span>, then the resulting contract is
a flat contract, and the <span class="RktVar">c</span> arguments must also be flat contracts. Such
flat contracts will be unsound if applied to a mutable data structure, as they will not
check future operations on the vector.</p><p>If the <span class="RktVar">immutable</span> argument is <span class="RktVal">#t</span> and the <span class="RktVar">c</span> arguments are
flat contracts, the result will be a flat contract. If the <span class="RktVar">c</span> arguments
are chaperone contracts, then the result will be a chaperone contract.</p><p><div class="SIntrapara">Examples:</div><div class="SIntrapara"><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">module</span><span class="hspace"> </span><span class="RktSym">server8</span><span class="hspace"> </span><span class="RktSym">racket</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">require</span><span class="hspace"> </span><span class="RktSym">racket/contract/option</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">provide</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktSym">change</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=attaching-contracts-to-values.html%23%2528form._%2528%2528lib._racket%252Fcontract%252Fbase..rkt%2529._contract-out%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">contract-out</a></span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">vec</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="#%28def._%28%28lib._racket%2Fcontract%2Foption..rkt%29._invariant%2Fc%29%29" class="RktValLink" data-pltdoc="x">invariant/c</a></span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=data-structure-contracts.html%23%2528def._%2528%2528lib._racket%252Fcontract%252Fprivate%252Fmisc..rkt%2529._any%252Fc%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">any/c</a></span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktSym">sorted?</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">define</span><span class="hspace"> </span><span class="RktSym">vec</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">vector</span><span class="hspace"> </span><span class="RktVal">1</span><span class="hspace"> </span><span class="RktVal">2</span><span class="hspace"> </span><span class="RktVal">3</span><span class="hspace"> </span><span class="RktVal">4</span><span class="hspace"> </span><span class="RktVal">5</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">define</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">change</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">vector-set!</span><span class="hspace"> </span><span class="RktSym">vec</span><span class="hspace"> </span><span class="RktVal">2</span><span class="hspace"> </span><span class="RktVal">42</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">define</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">sorted?</span><span class="hspace"> </span><span class="RktSym">vec</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">for/and</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktPn">[</span><span class="RktSym">el</span><span class="hspace"> </span><span class="RktSym">vec</span><span class="RktPn">]</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">cel</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">vector-drop</span><span class="hspace"> </span><span class="RktSym">vec</span><span class="hspace"> </span><span class="RktVal">1</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><=</span><span class="hspace"> </span><span class="RktSym">el</span><span class="hspace"> </span><span class="RktSym">cel</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr></table></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">require</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">server8</span><span class="RktPn">)</span></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">vector-set!</span><span class="hspace"> </span><span class="RktSym">vec</span><span class="hspace"> </span><span class="RktVal">2</span><span class="hspace"> </span><span class="RktVal">42</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktErr">vec: contract violation</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">expected vector that satisfies #<procedure:sorted?> given:</span></p></td></tr><tr><td><p><span class="RktErr">'#(1 2 42 4 5)</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">in: (invariant/c any/c #<procedure:sorted?>)</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">contract from: server8</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">blaming: top-level</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">(assuming the contract is correct)</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">at: eval:37.0</span></p></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">change</span><span class="RktPn">)</span></td></tr><tr><td><span class="stt">> </span><span class="RktPn">(</span><span class="RktSym">vector-ref</span><span class="hspace"> </span><span class="RktSym">vec</span><span class="hspace"> </span><span class="RktVal">2</span><span class="RktPn">)</span></td></tr><tr><td><p><span class="RktErr">vec: broke its own contract</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">expected vector that satisfies #<procedure:sorted?> given:</span></p></td></tr><tr><td><p><span class="RktErr">'#(1 2 42 4 5)</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">in: (invariant/c any/c #<procedure:sorted?>)</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">contract from: server8</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">blaming: server8</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">(assuming the contract is correct)</span></p></td></tr><tr><td><p><span class="RktErr"></span><span class="hspace"> </span><span class="RktErr">at: eval:37.0</span></p></td></tr></table></blockquote></div></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, "6.7", "../");" onfocus="this.style.color="black"; this.style.textAlign="left"; if (this.value == "...search manuals...") this.value="";" onblur="if (this.value.match(/^ *$/)) { this.style.color="#888"; this.style.textAlign="center"; this.value="...search manuals..."; }"/></form> <a href="../index.html" title="up to the documentation top" data-pltdoc="x" onclick="return GotoPLTRoot("6.7");">top</a></span><span class="navright"> <span class="nonavigation">← prev</span> <a href="../index.html" title="up to the documentation top" data-pltdoc="x" onclick="return GotoPLTRoot("6.7");">up</a> <span class="nonavigation">next →</span></span> </div></div></div><div id="contextindicator"> </div></body></html>
|