"Nick Sabalausky" <a...@a.a> wrote in message news:i2o9ev$1e4...@digitalmars.com... > "bearophile" <bearophileh...@lycos.com> wrote in message > news:i2nqs5$js...@digitalmars.com... >> It seems to work, on 2.042, and on dmd 2.047: >> http://ideone.com/dcsK3 >> >> Bye, >> bearophile > > That's because my original example accidentally made Foo an uninstantiated > class template, so the compiler never bothered to check the semantics... > > The following fails on 2.046 and 2.042, but works fine on 1.062: > > class Foo { > void bar(string s) {} > void foo() { > string str = "hello"; > str.bar(); > } > } > void main() {}
The above also fails on 2.047