caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Matej Kosik <5764c029b688c1c0d24a2e97cd764f@gmail.com>
To: caml-list <caml-list@inria.fr>
Subject: [Caml-list] Error: This variant or record definition does not match that of type ... Their kinds differ.
Date: Thu, 17 Aug 2017 15:55:18 +0200	[thread overview]
Message-ID: <2389e7d7-5590-22d6-3322-605d9a5b20c3@gmail.com> (raw)

Hi,

If my "b.mli" file contains the following code:

(*1*)  module rec A :
(*2*)  sig
(*3*)    type t = T1
(*4*)  end
(*5*)
(*6*)  and B :
(*7*)  sig
(*8*)    type t = A.t = T1
(*9*)  end

and I try to compile it like this:

  ocamlc -c b.ml

then I get the following error:

  File "b.mli", line 8, characters 9-26:
  Error: This variant or record definition does not match that of type A.t
         Their kinds differ.

I am wondering what does this error message mean?
What is the kind of A.t?
What is the kind of B.t?
Why are the kinds of of B.t and A.t different?

             reply	other threads:[~2017-08-17 13:50 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-17 13:55 Matej Kosik [this message]
2017-08-17 13:58 ` Matej Kosik

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=2389e7d7-5590-22d6-3322-605d9a5b20c3@gmail.com \
    --to=5764c029b688c1c0d24a2e97cd764f@gmail.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;
as well as URLs for NNTP newsgroup(s).