From: Martin Jambon <martin.jambon@ens-lyon.org>
To: Joel Reymont <joelr1@gmail.com>
Cc: skaller <skaller@users.sourceforge.net>, Caml List <caml-list@inria.fr>
Subject: Re: [Caml-list] Transforming of ASTs and polymorphic variants
Date: Tue, 24 Apr 2007 23:28:48 -0700 (PDT) [thread overview]
Message-ID: <Pine.LNX.4.64.0704242318001.3278@droopy> (raw)
In-Reply-To: <D034D091-126C-4CAB-81EF-177170305179@gmail.com>
On Wed, 25 Apr 2007, Joel Reymont wrote:
> John,
>
>> let conv_type x = (x : A.typ :> B.ty)
>>
>> will also work in this case.
>
> Thanks for the tip!
>
> Can you explain the following expression?
>
> (x : A.typ :> B.ty)
Basically you would use :> to convert the type of a value to a type which
is more general. With polymorphic variants it allows you to "add" cases
and with objects it allows you to "remove" methods.
Martin
--
Martin Jambon
http://martin.jambon.free.fr
prev parent reply other threads:[~2007-04-25 6:28 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-04-25 4:19 Joel Reymont
2007-04-25 4:56 ` Joel Reymont
2007-04-25 5:54 ` [Caml-list] " skaller
2007-04-25 5:59 ` Joel Reymont
2007-04-25 6:28 ` Martin Jambon [this message]
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=Pine.LNX.4.64.0704242318001.3278@droopy \
--to=martin.jambon@ens-lyon.org \
--cc=caml-list@inria.fr \
--cc=joelr1@gmail.com \
--cc=skaller@users.sourceforge.net \
/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