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 778807FA4D for ; Fri, 1 Aug 2014 13:04:03 +0200 (CEST) Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of Kim.Nguyen@lri.fr) identity=pra; client-ip=129.175.212.64; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="Kim.Nguyen@lri.fr"; x-sender="Kim.Nguyen@lri.fr"; x-conformance=sidf_compatible Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of Kim.Nguyen@lri.fr) identity=mailfrom; client-ip=129.175.212.64; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="Kim.Nguyen@lri.fr"; x-sender="Kim.Nguyen@lri.fr"; x-conformance=sidf_compatible Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of postmaster@mx1.u-psud.fr) identity=helo; client-ip=129.175.212.64; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="Kim.Nguyen@lri.fr"; x-sender="postmaster@mx1.u-psud.fr"; x-conformance=sidf_compatible X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Ah0BAExz21OBr9RAnGdsb2JhbABbg19XBLFqWJk+h1N/CBYQAQEBAQEICwkJFCmEAwEBBHoFFgsNUBMFIxOIOgjJZhePTIRSBZt1gVSFTYtdhSVq X-IPAS-Result: Ah0BAExz21OBr9RAnGdsb2JhbABbg19XBLFqWJk+h1N/CBYQAQEBAQEICwkJFCmEAwEBBHoFFgsNUBMFIxOIOgjJZhePTIRSBZt1gVSFTYtdhSVq X-IronPort-AV: E=Sophos;i="5.01,779,1400018400"; d="scan'208";a="73586653" Received: from mx1.u-psud.fr ([129.175.212.64]) by mail3-smtp-sop.national.inria.fr with ESMTP; 01 Aug 2014 13:04:02 +0200 Received: from mx1.u-psud.fr (localhost [127.0.0.1]) by localhost (MTA) with SMTP id 7358F302102 for ; Fri, 1 Aug 2014 13:04:02 +0200 (CEST) Received: from ext.lri.fr (ext.lri.fr [129.175.15.4]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.u-psud.fr (MTA) with ESMTPS id 489A5302077 for ; Fri, 1 Aug 2014 13:04:02 +0200 (CEST) Received: from [129.175.15.4] (ext.lri.fr [129.175.15.4]) by ext.lri.fr (Postfix) with ESMTP id 360D5406CE for ; Fri, 1 Aug 2014 13:04:02 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at lri.fr Received: from [129.175.15.4] (ext.lri.fr [129.175.15.4]) by localhost (ext.lri.fr [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id CuR939ZPNFUv for ; Fri, 1 Aug 2014 13:04:02 +0200 (CEST) Received: from [129.175.15.4] (ext.lri.fr [129.175.15.4]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (No client certificate requested) by ext.lri.fr (Postfix) with ESMTPSA id D2DCB3F64B for ; Fri, 1 Aug 2014 13:04:01 +0200 (CEST) Received: by mail-ig0-f170.google.com with SMTP id h3so3329368igd.3 for ; Fri, 01 Aug 2014 04:03:59 -0700 (PDT) X-Gm-Message-State: ALoCoQnvlPKrWGFY0l+Mst40UJgB13HR6HfKNcEpbVH63SbFTotByFsgO8qLLB7hFwvAR4xMu9pF X-Received: by 10.51.17.34 with SMTP id gb2mr6599939igd.16.1406891039631; Fri, 01 Aug 2014 04:03:59 -0700 (PDT) MIME-Version: 1.0 Received: by 10.107.25.200 with HTTP; Fri, 1 Aug 2014 04:03:19 -0700 (PDT) From: =?UTF-8?B?S2ltIE5ndXnhu4Vu?= Date: Fri, 1 Aug 2014 13:03:19 +0200 Message-ID: To: "Richard W.M. Jones" Cc: caml-list@inria.fr Content-Type: text/plain; charset=ISO-8859-1 X-Validation-by: kim.nguyen@lri.fr Subject: Re: [Caml-list] Bug in camlp4 4.02 ? [ was: cduce on ocaml 4.02 ] Hi Richard, hi everyone, On Thu, Jul 31, 2014 at 4:21 PM, Richard W.M. Jones wrote: > > I wonder if anyone has managed to compile cduce with OCaml 4.02? > > Currently it fails at: > > File "parser/parser.ml", line 2, characters 0-6: > Error: Unbound constructor Ulexer note: for me it "fails" (I kill ocamlopt) before because of a long forgotten -inline 10000 that makes ocaml generate a large ( >90 MB .s file on which "as" takes a lot of time, for typing/typer.ml), putting a saner -inline 100 in Makefile.distribg makes the file compile and I can stumble on the same camlp4 issue: > The post-preprocessor code looks very wrong to me: > > let _ = Ulexer ## generated from input "open Ulexer" > > let tloc (i, j) = (i, (* let raise = Pervasives.raise *) j) > > let nopos = ((-1), (-1)) > > It could be a bug in camlp4? The following test cases exhibit the problematic behavior of camlp4 (I don't know if it's just an intended change in behaviour or a bug, I don't mind filling a bug report in the latter case): bug1.ml ----------------------- #load "pa_extend.cmo";; open A open B open C open D open E bug2.ml ----------------------- #load "pa_extend.cmo";; open A open B open C open D open E open F $ camlp4 -version 4.02.0+dev12-2014-07-30 $ camlp4o bug1.ml E $ camlp4o bug2.ml let _ = E open F Note that if I don't go until "open E" the output file is empty with camlp4 from ocaml 4.01.0, everything works as expected (that is the #load is absent from the output, and all the open A...F are present in the output). Cheers, -- Kim