Bug 7103 – the -property switch vs. template functions with default template arguments

Status
RESOLVED
Resolution
WONTFIX
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
Other
OS
Windows
Creation time
2011-12-13T04:58:00Z
Last change time
2017-06-25T11:40:22Z
Assigned to
nobody
Creator
webby

Comments

Comment #0 by webby — 2011-12-13T04:58:22Z
if you compile the following code using the DMD 2.057 beta, using the -property switch, then you get no warning or error. ///////////////////////////////////////////////// import std.stdio; struct duck { void quack(int I1, int I2 = 0)(bool louder = false) { if (louder) writeln("QUACK"); else writeln("quack"); } } void main() { duck d; d.quack!(0); } ///////////////////////////////////////////////// However, if you change it to d.quack!(0, 0); then you get Error: not a property d.quack Shouldn't both cases behave the same?
Comment #1 by ellery-newcomer — 2012-09-17T20:41:59Z
dmd 2.060 both versions get you Error: not a property d.quack
Comment #2 by dlang-bugzilla — 2017-06-25T11:40:22Z
The -property switch has been deprecated and no longer has any effect, closing.