Hello, Am Dienstag, den 07.02.2012, 13:04 +0100 schrieb Hendrik Tews:
> how do you compile your sample file? When I compile with ocamlc I > get I compiled it with ocamlopt > > File "brackets.ml", line 3, characters 0-2: > Error: Comment not terminated > > I believe it's an OCaml feature, that strings inside comments > must be terminated (but I cannot find it in the manual). That would be a very strange feature, IMHO. But if so, it is not documented. > > Andreas Romeyke <andreas.rome...@dzb.de> writes: > > If you add somewhere in your code a comment with open quotation, the > > Do you actually mean a comment with a lonely quotation mark char > (`"') or do you mean a comment with a lonely camlp4/camlp5 In the bugreport there is a sample file, I mean lonely quotation mark char (`"') > quotation marker (`<<' or `>>') ? That will be another bug, which will possibly related to the report bug. But I could not generate a sample file... > > compiler > sometimes produces binaries with partial broken functionality or aborts > compilation with error message of this pattern: > > Could it be that you had code such as > > let f = function > | A -> 0 (* " *) > | B -> 1 (* " *) > | C -> 2 > > where the B-case is in fact inside a string inside the _single_ > comment in f? (Which you easily see because the compiler says > "pattern matching not exhaustive".) No, it will be not. (Checked with vim's bracket-matching) > We hat a heisenbug where the compiler creates a working binary without > any > error-message, but completely different behaviour, if somewhere was a > comment > of form (* << *) or (* >> *), but this was very hard to reproduce and > catch in > an example-file. > > From this I would guess that this bug should actually be assigned > to camlp4 or camlp5. > > Maybe you had > > (* << *) > some code > (* >> *) > > ? Then ``some code'' is inside a quotation inside a comment. That will not be easily to discover. Could you fix/ask about the reported bug with quotation mark char? Thanks in advance... :) Bye Andreas -- Andreas Romeyke - Abteilung Blindenschrift - Deutsche Zentralbücherei für Blinde zu Leipzig (DZB) Gustav-Adolf-Straße 7, 04105 Leipzig Tel: +49 341 7113-..., Fax: +49 341 7113-125 Internet: www.dzb.de E-Mail: andreas.rome...@dzb.de
signature.asc
Description: This is a digitally signed message part