[Issue 3321] debug flags

d-bugmail at puremagic.com d-bugmail at puremagic.com
Thu Sep 17 07:44:39 PDT 2009


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



--- Comment #3 from Ellery Newcomer <ellery-newcomer at utulsa.edu> 2009-09-17 07:44:38 PDT ---
(In reply to comment #2)
> Yes, that's normal behaviour.

According to whom? The C preprocessor?

When I read the spec, I came away with the impression that debug should work
like so:

debug { stuff } should get compiled if the compiler is given -debug or
-debug={something}. Basically, I see it as a boolean. Are we in a debug
compile?

debug(number) { stuff } should get compiled if the compiler is given -debug=n,
where n >= number (and there's nothing that says debug(0) { stuff } will always
get compiled)

wait, I'm seeing a pattern here 1 -> true, 0 -> false. That sorta makes sense.

debug(id) { stuff } should get compiled if the compiler is given -debug=id


Yeah, spec needs to be more precise. I would like to see -debug=id =>
debug_level=1, though.

-- 
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