From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-0.9 required=5.0 tests=BAYES_00,FORGED_GMAIL_RCVD, FREEMAIL_FROM autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,bdebc54a485c13a4 X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Received: by 10.68.125.233 with SMTP id mt9mr13827366pbb.5.1332582609262; Sat, 24 Mar 2012 02:50:09 -0700 (PDT) Path: kz5ni27782pbc.0!nntp.google.com!news2.google.com!goblin1!goblin.stu.neva.ru!eternal-september.org!feeder.eternal-september.org!mx04.eternal-september.org!.POSTED!not-for-mail From: Natasha Kerensikova Newsgroups: comp.lang.ada Subject: Re: My first compiler bug: work around or redesign? Date: Sat, 24 Mar 2012 09:50:08 +0000 (UTC) Organization: A noiseless patient Spider Message-ID: References: <10kx1zr05qt9s$.ab8q1peu0ukt.dlg@40tude.net> <4f6d0f78$0$6623$9b4e6d93@newsspool2.arcor-online.net> Mime-Version: 1.0 Injection-Date: Sat, 24 Mar 2012 09:50:08 +0000 (UTC) Injection-Info: mx04.eternal-september.org; posting-host="Mda950WjNwNLAFOE7yJXQw"; logging-data="27044"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+4ifqHkXvbMwCEHUZ7FVbL" User-Agent: slrn/0.9.9p1 (FreeBSD) Cancel-Lock: sha1:XROcezW37JiEVgMs5/XntVdx9iM= Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Date: 2012-03-24T09:50:08+00:00 List-Id: On 2012-03-24, Georg Bauhaus wrote: > A bug seems present, with or without switches, in GNAT GPL 2011/Mac, too. > > +===========================GNAT BUG DETECTED==============================+ >| GPL 2011 (20110419) (x86_64-apple-darwin10.2.0) GCC error: | >| in gnat_to_gnu_entity, at ada/gcc-interface/decl.c:4121 | >| Error detected at dressup-parsers-markdown.adb:184:4 [dressup-parsers-markdown.adb:1651:7 [markdown.adb:32:4]]| > > From the looks of it, it seems there is a probability that > the bug is related to passing information between GNAT > and other parts of GCC. The rest is speculation by mere mortals :-) According to you and Simon Wright, it seems useful to report this bug then. Now I just have to figure out to who and how, and maybe work out a minimal test case. I still have trouble interpreting Jeffrey Carter's results though. > I worked around by adding switch -gnat95 and then mechanically following > the compiler's complaints. Less than I did might do the trick, though, > with GNAT at least, or any compiler that accepts Ada 2005 from the RTS in > Ada 95 programs. > > http://home.arcor.de/bauhaus/Ada/Dressup-bf54531f8dcf7117.diff > > (A huge fraction of the patch is just syntax.) Thanks a lot, I will try to study that patch. I'm still surprised 2005 vs 95 can have something to do with it. > The resulting executable bin/markdown does output HTML for > *, \n==, etc., but I'm not sure that I have been sufficiently meticulous. > (Is bin/markdown supposed to successfully run a test suite yet? > I found test cases in something called MarkdownTest_1.0.zip, > which has a driver program written in Perl in it. I haven't used > it directly, but fed Tests/Tabs.text from this distribution > to bin/markdown and compared the results, just to see if I hadn't > messed up). It is supposed to almost pass the test. It's a redesign from a previous-working but (IMHO) ugly version, available at http://fossil.instinctive.eu/dressup/info/de3a2cbc2d Specifically, the "known failures", that I consider as "won't fix" are: - I don't add an extra end-of-line when the file does not end with one, but that only makes a difference in code blocks, with being at the end of the line vs on the next line. - I don't render empty href attributes, so there is a stuff vs stuff. - I don't remove spaces in a line that only contain them, again that is only significant in code blocks (in "Markdown Documentation - Basics.text" there is a code block with two lines containing only 8 spaces, 4 of them are removed as the code block marker, and the remaining 4 are output, while the reference HTML has a spaceless empty line instead). Thanks again for your help, Natasha