https://issues.dlang.org/show_bug.cgi?id=22961
Issue ID: 22961
Summary: importC: K&R-style main function rejected
Product: D
Version: D2
Hardware: All
OS: All
Status: NEW
Keywords: ImportC, rejects-valid
Severity: normal
Priority: P1
Component: dmd
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected]
int main(argc, argv)
int argc;
char **argv;
{
return 0;
}
test.c(4): Error: function `test.main` parameters must match one of the
following signatures
test.c(4): `main()`
test.c(4): `main(int argc, char** argv)`
test.c(4): `main(int argc, char** argv, char** environ)` [POSIX
extension]
this used to work before the error was added in
https://github.com/dlang/dmd/pull/13749
--