caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* [Caml-list] selecting GADT parameter
@ 2015-07-31 13:48 Ashish Agarwal
  2015-07-31 13:57 ` Carl Eastlund
  2015-08-04  9:21 ` Goswin von Brederlow
  0 siblings, 2 replies; 7+ messages in thread
From: Ashish Agarwal @ 2015-07-31 13:48 UTC (permalink / raw)
  To: Caml List

[-- Attachment #1: Type: text/plain, Size: 271 bytes --]

I have:

type _ t =
| Foo1 : 'a * int -> int t
| Foo2 : 'a * string -> 'a t

but I really want to merge these two cases. I want the return type to be
based on the second arg when the second arg is int, and be based on the
first arg otherwise. Any way to accomplish that?

[-- Attachment #2: Type: text/html, Size: 394 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2015-08-05 17:27 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-07-31 13:48 [Caml-list] selecting GADT parameter Ashish Agarwal
2015-07-31 13:57 ` Carl Eastlund
2015-07-31 14:18   ` Ashish Agarwal
2015-07-31 14:31     ` Lukasz Stafiniak
2015-07-31 14:33     ` Runhang Li
2015-08-04  9:21 ` Goswin von Brederlow
2015-08-05 17:26   ` Ashish Agarwal

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).