Bug 19995 – parameter attributes are accepted in parameter-less functions
Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2019-06-22T14:05:54Z
Last change time
2019-06-23T02:47:20Z
Keywords
accepts-invalid, pull
Assigned to
No Owner
Creator
Basile-z
Comments
Comment #0 by b2.temp — 2019-06-22T14:05:54Z
---
int test(const @tation)
{
return 0;
}
void main()
{
test();
}
---
1. `tation` isn't even a thing
2. this should be rejected because for example `in` attribute can be a typo in `int`.