digitalmars.D - Another Shared Bug?
- Andrew Wiley (42/42) Oct 24 2011 My understanding is that this:
- Dmitry Olshansky (6/48) Oct 24 2011 Mm maybe it complains about i being property and not a function? Though
My understanding is that this: -------- module test2; synchronized abstract class Bob { private: int _i = 2; public: property int i() { return _i; } } synchronized class Bill : Bob { public: property int thing() { return i; } } -------- should be the same as this: -------- module test2; synchronized abstract class Bob { private: int _i = 2; public: property int i() { return _i; } } synchronized class Bill : Bob { public: property int thing() { return super.i(); //test2.d(18): Error: function test2.Bob.i () shared is not callable using argument types () } } -------- But the second one gets a compiler error. Bug?
Oct 24 2011
On 25.10.2011 2:34, Andrew Wiley wrote:My understanding is that this: -------- module test2; synchronized abstract class Bob { private: int _i = 2; public: property int i() { return _i; } } synchronized class Bill : Bob { public: property int thing() { return i; } } -------- should be the same as this: -------- module test2; synchronized abstract class Bob { private: int _i = 2; public: property int i() { return _i; } } synchronized class Bill : Bob { public: property int thing() { return super.i(); //test2.d(18): Error: function test2.Bob.i () shared is not callable using argument types ()Mm maybe it complains about i being property and not a function? Though that was forced yet(?). Does plain super.i without () work here? Sometimes error messages are plain wrong. In ether case it seems like a bug.} } -------- But the second one gets a compiler error. Bug?-- Dmitry Olshansky
Oct 24 2011