[racket] matching (var pat)

From: Marco Maggesi (marco.maggesi at gmail.com)
Date: Sun Feb 20 13:01:32 EST 2011

Hi,

I noticed that (var pat) has a special meaning in pattern matching, i.e.,
the following program

#lang racket
(struct var (name))
(match (var "x")
  [(var name) name])

returns (var "x") instead of "x" as I would expected.

However it seems that this is not mentioned in the documentation.

M.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.racket-lang.org/users/archive/attachments/20110220/e2392bc9/attachment.html>

Posted on the users mailing list.