title: Binding pattern matches to identifiers in Racket
body: <p>Is there an easy way to imitate the <code>as</code> keyword from OCaml like this:</p>
  
  <pre><code>(match x with
   |((a,b) as c, d) -&gt; c)
  </code></pre>
  
  <p>in Racket? I thought about defining a syntax rule in order to handle the syntax <code>((exp) as id)</code>, but then I run across the issue of exp potentially having more <code>as</code> bindings. Any thoughts on how I might be able to extract all the <code>as</code> bindings from an expression and then give them a local binding in the expression of the match clause? Thanks!</p>