Mantis Bugtracker

Einfache Problemansicht anzeigen Zu Notizen wechseln ] erweiterte Anzeige ] Problem-Historie ] Drucken ]
ID Kategorie Auswirkung Reproduzierbar Meldungsdatum Letzte Aktualisierung
0000040 [Bisect] general kleinerer Fehler immer 2009-06-04 19:51 2009-06-07 17:20
Reporter mfurr Anzeigestatus öffentlich  
Bearbeitung durch xclerc
Priorität normal Lösung erledigt  
Status geschlossen   Produktversion
Zusammenfassung 0000040: Fails with << in comments
Beschreibung bisect seems to have trouble when '<<' and '>>' appear in comments.
Here's a small example:
 type t =
   | A (* << *)
   | B (* >> *)
Running 'camlp4o .../instrument.cma' on a file with this definition prints:
  let _ = Bisect.Runtime.init ""
  type t = | A

The constructor for B has disappeared!
Zusätzliche Information
Tags Keine Tags zugeordnet.
Angehängte Dateien

- Problem-Beziehungen

-  Notiz
xclerc (Administrator)
2009-06-05 21:41

A preliminary investigation seems to indicate that this problems stems
from camlp4's quotations (*). Camlp4 views the "<<" string as the start
of a quotation and ">>" as its end. Moreover, if no ">>" is provided,
camlp4 will complain, reporting that a quotation is not terminated.

My first interpretation is that this is a camlp4 bug but some in-depth
understanding of camlp4 is needed to confirm that. I have thus contacted
Nicolas Pouillard (camlp4 guru) and will update this report with any
additional information.

(*) [^]
xclerc (Administrator)
2009-06-07 17:20

Well, I have to made public apologies for the mistake in the previous note.
As explained by Nicolas Pouillard, the reported behaviour is indeed expected.

The idea is that quotations behaves here as strings would: when embedded
inside comments, they have to be properly closed (this behaviour is clearly
needed if you want to always be able to properly comment out strings or

On the reported example, this means that the comment opened right after
"A" ends on the "*)" that follows the end of the quotation. A similar example
on strings is that the following program will print "abc":
  let () = print_endline (* " ABC DEF *) " *) "abc"

The obvious conclusion is that this bug report is closed with no modification
on the code base. However, the next version of the manual will be enriched
with a note warning the Bisect user of possible camlp4 interactions.

- Problem-Historie
Änderungsdatum Benutzername Feld Änderung
2009-06-04 19:51 mfurr Neues Problem
2009-06-05 21:41 xclerc Problemnotiz hinzugefügt: 0000181
2009-06-05 21:41 xclerc Bearbeitung durch => xclerc
2009-06-05 21:41 xclerc Status neu => anerkannt
2009-06-07 17:20 xclerc Problemnotiz hinzugefügt: 0000184
2009-06-07 17:20 xclerc Status anerkannt => geschlossen
2009-06-07 17:20 xclerc Lösung offen => erledigt
2009-06-07 17:20 xclerc Behoben in Version => 1.0beta

Mantis 1.1.7[^]
Copyright © 2000 - 2008 Mantis Group
Powered by Mantis Bugtracker