[Issue 21647] New: pragma(msg) should be able to print a void type
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Fri Feb 19 09:39:00 UTC 2021
https://issues.dlang.org/show_bug.cgi?id=21647
Issue ID: 21647
Summary: pragma(msg) should be able to print a void type
Product: D
Version: D2
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: P1
Component: dmd
Assignee: nobody at puremagic.com
Reporter: bugzilla at digitalmars.com
The following:
alias V = void;
pragma(msg, V);
should print:
void
And it does when the pragma is inside a function! But when it as global level,
it prints:
Error: Cannot pass argument void to pragma msg because it is void
This problem was introduced in https://github.com/dlang/dmd/pull/7316 as a fix
for https://issues.dlang.org/show_bug.cgi?id=17382. Unfortunately, it altered
the code for PragmaDeclaration but not PragmaStatement, hence the difference.
But the 17382 bug remains.
Essentially, 7316 was not a correct fix for 17382.
--
More information about the Digitalmars-d-bugs
mailing list