From: Fernando Alegre <fernando@cc.gatech.edu>
To: Andrej.Bauer@andrej.com
Cc: caml-list@inria.fr
Subject: Re: RE : [Caml-list] empty type
Date: Mon, 19 Feb 2007 15:51:24 -0500 [thread overview]
Message-ID: <20070219205124.GA12113@gaia.cc.gatech.edu> (raw)
In-Reply-To: <45D9CA6E.8020008@fmf.uni-lj.si>
How about this:
# type t = () of int;;
type t = () of int
# begin end;;
The constructor () expects 1 argument(s),
but is here applied to 0 argument(s)
Fernando
On Mon, Feb 19, 2007 at 05:03:58PM +0100, Andrej Bauer wrote:
> Mathias Kende wrote:
> >It's not a type, but just a valid name for a constructor that can be
> >redefined if necessary (although one surely does not want to do so).
>
> Way cool:
>
> # type t = () of int * int ;;
> type t = () of int * int
> # () (3, 4) ;;
> - : t = () (3, 4)
>
> Andrej
>
> _______________________________________________
> Caml-list mailing list. Subscription management:
> http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list
> Archives: http://caml.inria.fr
> Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
> Bug reports: http://caml.inria.fr/bin/caml-bugs
next prev parent reply other threads:[~2007-02-19 20:51 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-02-19 13:47 Fernando Alegre
2007-02-19 14:14 ` [Caml-list] " skaller
2007-02-19 14:23 ` RE : " Mathias Kende
2007-02-19 16:03 ` Andrej Bauer
2007-02-19 20:51 ` Fernando Alegre [this message]
2007-02-20 9:05 ` Bruno De Fraine
2007-02-19 22:36 ` Richard Jones
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20070219205124.GA12113@gaia.cc.gatech.edu \
--to=fernando@cc.gatech.edu \
--cc=Andrej.Bauer@andrej.com \
--cc=caml-list@inria.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox