Bug 17865 – property/non-property overloads not detected until used

Status
NEW
Severity
normal
Priority
P3
Component
dmd
Product
D
Version
D2
Platform
x86
OS
Windows
Creation time
2017-09-28T18:44:00Z
Last change time
2024-12-13T18:54:44Z
Assigned to
No Owner
Creator
forsaken
Moved to GitHub: dmd#19323 →

Comments

Comment #0 by nicolas.jinchereau — 2017-09-28T18:44:00Z
class C { @property void fun(int x){ } int fun(){ return 0; } } int main(string[] argv) { C c = new C(); //c.fun = 0; return 0; } This code should not compile, but it does. You have to un-comment the second line of main before you get the proper error: "Error: cannot overload both property and non-property functions"
Comment #1 by robert.schadek — 2024-12-13T18:54:44Z
THIS ISSUE HAS BEEN MOVED TO GITHUB https://github.com/dlang/dmd/issues/19323 DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB