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 022857FCF8 for ; Thu, 2 Apr 2015 17:42:21 +0200 (CEST) Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of edwin+ml-ocaml@etorok.net) identity=pra; client-ip=62.113.205.31; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="edwin+ml-ocaml@etorok.net"; x-sender="edwin+ml-ocaml@etorok.net"; x-conformance=sidf_compatible Received-SPF: Pass (mail3-smtp-sop.national.inria.fr: domain of edwin+ml-ocaml@etorok.net designates 62.113.205.31 as permitted sender) identity=mailfrom; client-ip=62.113.205.31; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="edwin+ml-ocaml@etorok.net"; x-sender="edwin+ml-ocaml@etorok.net"; 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@mx.etorok.net) identity=helo; client-ip=62.113.205.31; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="edwin+ml-ocaml@etorok.net"; x-sender="postmaster@mx.etorok.net"; x-conformance=sidf_compatible X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: A0AZFACnYh1V/x/NcT5cgwiBLoMVyEACgUZMAQEBAQEBfkEBAYNcAQUjDwENOg8LGAICBRMOAgIPAkYTCAKIL7R/cIRok2wGgSGKCIUAFoJSgUWLI49MgR2GEo0ZIoNxOzGCQwEBAQ X-IPAS-Result: A0AZFACnYh1V/x/NcT5cgwiBLoMVyEACgUZMAQEBAQEBfkEBAYNcAQUjDwENOg8LGAICBRMOAgIPAkYTCAKIL7R/cIRok2wGgSGKCIUAFoJSgUWLI49MgR2GEo0ZIoNxOzGCQwEBAQ X-IronPort-AV: E=Sophos;i="5.11,511,1422918000"; d="scan'208";a="108116914" Received: from mx.etorok.net ([62.113.205.31]) by mail3-smtp-sop.national.inria.fr with ESMTP/TLS/DHE-RSA-AES256-SHA; 02 Apr 2015 17:42:21 +0200 Received: by mx.etorok.net (OpenSMTPD) with ESMTP id d4115762; for ; Thu, 2 Apr 2015 18:42:19 +0300 (EEST) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=etorok.net; h= message-id:date:from:mime-version:to:subject:references :in-reply-to:content-type:content-transfer-encoding; s=ml; bh=1w PCfTggtn8ZHZ9BuNhqPyLlZs8=; b=lLsJQ5luXyArzUwcsAy/wax4ufYS2+YcKk hEAiqSHYrflkKEJ49T2Hxq+QJdeoh2kQ9W8972URe1X8KdhQcWr3yxUkmkQljxYy 5rmbNQSPN1oAKt5oj4NPw9eO7Puo3ExKID2VLHVaMdsDWfvBqXtNgIYkLcdjd4u3 cGV3LXWD4= Received: by mx.etorok.net (OpenSMTPD) with ESMTPSA id 89273081; TLS version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NO; for ; Thu, 2 Apr 2015 18:42:19 +0300 (EEST) Message-ID: <551D635A.90506@etorok.net> Date: Thu, 02 Apr 2015 18:42:18 +0300 From: =?UTF-8?B?VMO2csO2ayBFZHdpbg==?= User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Icedove/31.5.0 MIME-Version: 1.0 To: caml-list@inria.fr References: In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Subject: Re: [Caml-list] Strange result with Lexing On 04/02/2015 06:22 PM, Sébastien Dailly wrote: > Hello, > > I've found a strange result when calling Lexing.lexeme_start and Lexing.lexeme_end on DOS format file (with \r\n instead of \n). > > The value returned by the two functions is wrong when the file is in DOS format (the result does not change when I convert the file in UNIX format, but this is what I expect). > > I there something I misunderstood in the documentation ? > > (I've compiled ocaml with opam on cygwin). > Do you use 'open_in' or 'open_in_bin' to read the file? --Edwin