[Issue 5921] No mismatched nested comments

d-bugmail at puremagic.com d-bugmail at puremagic.com
Tue May 3 11:02:25 PDT 2011


http://d.puremagic.com/issues/show_bug.cgi?id=5921



--- Comment #5 from kennytm at gmail.com 2011-05-03 10:58:33 PDT ---
(In reply to comment #4)
> (In reply to comment #3)
> > Not a dmd issue, marked as invalid.
> 
> But isn't it a DMD problem still? Maybe we have discussed this same problem in
> past, but the comments are not mismatched here.

No they are mismatched.

Inside a /+ ... +/, the /* ... */ is not special. Therefore, the tokenizer,
using greedy match, recognizes the input as:

<start-of-nestable-comment> /+
<comment-text>              /*
                            *
<start-of-nestable-comment> /+
<comment-text>              /
                            void main() {}

Therefore you have two +/ unmatched.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list