July 22, 2004 Compilation error missing file name and line number | ||||
|---|---|---|---|---|
| ||||
Both of the following (when compiled individually, of course) report the error 'cannot have parameter of type void', but no file name or line number is reported:
typedef void function(void) illegal;
typedef void (*illegal)(void);
This error only occurs when 'typedef' is used. The following all print the file name and line number as expected:
alias void function(void) illegal;
alias void (*illegal)(void);
void (*illegal)(void);
void illegal(void) {}
| ||||
Copyright © 1999-2021 by the D Language Foundation
Permalink
Reply