From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@sympa.inria.fr Delivered-To: caml-list@sympa.inria.fr Received: from mail3-relais-sop.national.inria.fr (mail3-relais-sop.national.inria.fr [192.134.164.104]) by sympa.inria.fr (Postfix) with ESMTPS id 9A8707EE51 for ; Sat, 13 Apr 2013 08:50:22 +0200 (CEST) Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of anthony.tavener@gmail.com) identity=pra; client-ip=74.125.83.51; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="anthony.tavener@gmail.com"; x-sender="anthony.tavener@gmail.com"; x-conformance=sidf_compatible Received-SPF: Pass (mail3-smtp-sop.national.inria.fr: domain of anthony.tavener@gmail.com designates 74.125.83.51 as permitted sender) identity=mailfrom; client-ip=74.125.83.51; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="anthony.tavener@gmail.com"; x-sender="anthony.tavener@gmail.com"; x-conformance=sidf_compatible; x-record-type="v=spf1" Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of postmaster@mail-ee0-f51.google.com) identity=helo; client-ip=74.125.83.51; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="anthony.tavener@gmail.com"; x-sender="postmaster@mail-ee0-f51.google.com"; x-conformance=sidf_compatible X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AisFADb/aFFKfVMzk2dsb2JhbABQgzy5MwGIMQOBAAgWDgEBAQEHCwsJFAQkgk0ZARseAxIJAQZdAREBBQEiG4d5AQMPmzmCcowvgnuEMgoZJw1ZiH4BBQyONIQfA4kDjX+BIYpWgzgWKYRNHQ X-IPAS-Result: AisFADb/aFFKfVMzk2dsb2JhbABQgzy5MwGIMQOBAAgWDgEBAQEHCwsJFAQkgk0ZARseAxIJAQZdAREBBQEiG4d5AQMPmzmCcowvgnuEMgoZJw1ZiH4BBQyONIQfA4kDjX+BIYpWgzgWKYRNHQ X-IronPort-AV: E=Sophos;i="4.87,466,1363129200"; d="scan'208";a="10818999" Received: from mail-ee0-f51.google.com ([74.125.83.51]) by mail3-smtp-sop.national.inria.fr with ESMTP/TLS/RC4-SHA; 13 Apr 2013 08:50:22 +0200 Received: by mail-ee0-f51.google.com with SMTP id c4so1508766eek.10 for ; Fri, 12 Apr 2013 23:50:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:date:message-id:subject:from:to :content-type; bh=XYEHDT1DOa43jlF6Yoearpo92jb9xzDshNYKZy1ZpRw=; b=0PJjWttKEPJE3e+Gf/hYrRMYa/M9LlHx1VEfEnKCtOG1uKHFPZSW9njZ3oPAwZ5Hxt hcZtlBYij7qDVWxrsmoHG2mBT7Iu0pxWjNHctn25vekW1+tMqXwdAY87Pg9U8lisHiIe N+vmBT8ObYN8rAgohe4n+NhRgtVDi8azi+tpRSZ/Ujhi5iStA7kThpja3HXBbhNLDMvO V6egKPeqTW7OuPEu3zh2R6RHAfuhFTaYrDtO9bZdnXfTztoKoKrlTWurXmzjidEP9sU5 kjgjDEmMNwhT/+NDm9C/YEa9I53uJOAurwzPzbP8P7JRtncAs2okNqQUfKGFFo+AEZbL ixSQ== MIME-Version: 1.0 X-Received: by 10.15.102.3 with SMTP id bq3mr36110533eeb.42.1365835821442; Fri, 12 Apr 2013 23:50:21 -0700 (PDT) Received: by 10.14.7.4 with HTTP; Fri, 12 Apr 2013 23:50:21 -0700 (PDT) Date: Sat, 13 Apr 2013 00:50:21 -0600 Message-ID: From: Anthony Tavener To: "caml-list@inria.fr" Content-Type: multipart/alternative; boundary=089e01634f70f58a5904da386e15 Subject: [Caml-list] Types look compatible, but they aren't? --089e01634f70f58a5904da386e15 Content-Type: text/plain; charset=ISO-8859-1 File "virtue.ml", line 462, characters 12-24: Error: This expression has type int * ((int * int -> int * int) list -> exn) * (exn -> (int * int -> int * int) list) but an expression was expected of type int * ((< .. > as 'a) list -> exn) * (exn -> 'a list) The code in question: (fun id -> let m = Modifier.attach id in [ m Cast.total'k (fun (v,b) -> (v, max 1 (b-3))) (* <-- line 462 *) ; m Lab.total'k (fun (v,b) -> (v, max 1 (b-3))) ]) For reference, the signature of Modifier.attach: Db.key -> int * ('a list -> exn) * (exn -> 'a list) -> 'a -> Modifier.deleter OCaml version is 4.00.0 -- I know I should upgrade. Keep meaning to, I guess I will if I wake up and there's no helpful soul explaining what could be wrong here. :) Thank-you for any help. My eyes are starting to bug-out looking at this. -Tony --089e01634f70f58a5904da386e15 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
File "virtue.ml= ", line 462, characters 12-24:
Error: This expression has ty= pe
=A0 =A0 =A0 =A0 =A0int * ((int * int -> int * int) list -&g= t; exn) *
=A0 =A0 =A0 =A0 =A0(exn -> (int * int -> int * int) list)
<= div>=A0 =A0 =A0 =A0but an expression was expected of type
=A0 =A0= =A0 =A0 =A0int * ((< .. > as 'a) list -> exn) * (exn -> &#= 39;a list)

The code in question:

=A0 (= fun id ->
=A0 =A0 let m =3D Modifier.attach id in
= =A0 =A0 =A0 [ m Cast.total'k (fun (v,b) = -> (v, max 1 (b-3))) =A0 =A0 (* <-- line 462 *)
=A0 =A0 =A0 ; m Lab.total'k (fun (v,b) -> (v, max 1 (b-3))) ])<= /div>

For reference, the signature of Modifier.attach:
=A0 Db.key -> int * ('a list -> exn) * (exn -> 'a= list) -> 'a -> Modifier.deleter

OCaml version is 4.00.0 -- I know I should upgrade. Kee= p meaning to, I
guess I will if I wake up and there's no help= ful soul explaining what could
be wrong here. :)

Thank-you for any help. My eyes are starting to bug-out lo= oking at this.

=A0-Tony


--089e01634f70f58a5904da386e15--