caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Claudio Russo <crusso@microsoft.com>
To: Alain Frisch <frisch@clipper.ens.fr>
Cc: caml-list@inria.fr, kfl@it.edu, sestoft@dina.kvl.dk
Subject: RE: first class modules (was: alternative module systems)
Date: Mon, 8 Jan 2001 06:59:53 -0800	[thread overview]
Message-ID: <112C6E8A1B25D34BB27D48D2FD2E96CFC94299@TVP-MSG-02.europe.corp.microsoft.com> (raw)

 
> > For the record, your simplification based on identity of signature
> > identifiers
> > is probably ok in practice, but it does
> > rule out some examples that involve package types with free type
> > variables. 
> 
> Right. Would it break something to allow named module type with
> explicit arguments:
> 
> module type 'a ARRAY = sig
>    type array
>    val init: 'a -> array
>    val sub: array -> int -> 'a
>    val update : array -> int -> 'a -> array
> end
> 
> ?
> 
> Then the unification between < (a1,...,ap) S > and < (b1,...,bq) T >
> is solved by equating S = T (syntactically), p=q  and unifying
> a1=b1,...,ap=bp.


I think this would be fine, but you then also have to deal with the
meaning
of these parameterised signatures in other contexts, eg:

functor F(X: ('a -> int) S )= <modexp>;

and so on. Is this declaration illegal or should the functor F be
implicitly polymorphic in 'a?
This is not impossible to deal with, just needs some more work. I
suppose you could only allow
signature applications in core type expressions of the form < sigexp >,
but that seems a little hacky.

-c




> 
> -- 
>   Alain Frisch
> 
> 



             reply	other threads:[~2001-01-08 17:59 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-01-08 14:59 Claudio Russo [this message]
  -- strict thread matches above, loose matches on Subject: below --
2001-01-10 10:32 Claudio Russo
2001-01-09 13:36 Claudio Russo
2001-01-08 15:11 Claudio Russo
2001-01-08 13:48 Claudio Russo
2001-01-08 10:45 Claudio Russo
2001-01-08 12:17 ` Alain Frisch
2001-01-07  0:20 Alain Frisch
2001-01-07 23:26 ` Markus Mottl
2001-01-08 10:42 ` Xavier Leroy
2001-01-10  0:40   ` Brian Rogoff

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=112C6E8A1B25D34BB27D48D2FD2E96CFC94299@TVP-MSG-02.europe.corp.microsoft.com \
    --to=crusso@microsoft.com \
    --cc=caml-list@inria.fr \
    --cc=frisch@clipper.ens.fr \
    --cc=kfl@it.edu \
    --cc=sestoft@dina.kvl.dk \
    /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;
as well as URLs for NNTP newsgroup(s).