From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id KAA27778; Thu, 8 Jan 2004 10:49:00 +0100 (MET) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id KAA27883 for ; Thu, 8 Jan 2004 10:48:58 +0100 (MET) Received: from inria.fr (macaque.inria.fr [128.93.8.158]) by nez-perce.inria.fr (8.11.1/8.11.1) with ESMTP id i089mv523384 for ; Thu, 8 Jan 2004 10:48:57 +0100 (MET) Date: Thu, 8 Jan 2004 10:49:17 +0100 Subject: Re: [Caml-list] 3.07: debug information on camlp4-processed files is missing the file name? Content-Type: text/plain; charset=US-ASCII; format=flowed Mime-Version: 1.0 (Apple Message framework v553) From: Damien Doligez To: Caml List Content-Transfer-Encoding: 7bit In-Reply-To: <20040108081744.GC27608@fistandantilus.takhisis.org> Message-Id: X-Mailer: Apple Mail (2.553) X-Loop: caml-list@inria.fr X-Spam: no; 0.00; caml-list:01 3.07:01 camlp:01 damien:01 damien:01 camlp:01 annotations:01 debugger:01 backtrace:01 offsets:01 offsets:01 bug:01 debug:01 doligez:01 doligez:01 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk On Thursday, January 8, 2004, at 09:17 AM, Stefano Zacchiroli wrote: > Do this patch change also the output format of -dtypes option when used > in combination with camlp4? Yes. It changes the annotations in the parse tree, which are used for the debugger, the -dtypes option, error messages, backtrace, etc. > Actually while using camlp4, the .annot file > generated uses offsets that are all referred to the beginning of file; > while not using camlp4 offsets are referred to the beginning of each > line. The missing file name can be considered a bug. Otherwise, there are two possible formats: the old format (line 1, offset from the beginning of the file) and the new format (line, character). We are working to get rid of the old format before the next release of O'Caml. > I'm asking because I've written vim support for .annot files, but > actually it works only with non camlp4 generated .annot files ... If possible, you shouldn't count on the line number to be exact. Start at the beginning of the line, and go forward the given number of characters. Most of the time, you won't encounter any line break, but that's not strongly guaranteed. -- Damien ------------------- To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ Beginner's list: http://groups.yahoo.com/group/ocaml_beginners