D - bug? cannot implicitly convert int() to int
- Carlos Santander B. (16/16) Jan 25 2004 The following code produces: "cannot implicitly convert int() to int".
- Manfred Nowak (6/8) Jan 26 2004 It also works with `return a.b + 0;'.
The following code produces: "cannot implicitly convert int() to int".
import std.c.stdio;
struct A {
int b() { return 1; }
}
int x() {
A a;
return a.b;
}
void main () {
printf("%d\n",x());
}
I know I can make work doing "return a.b();", but what would be the purpose
of properties then?
-----------------------
Carlos Santander Bernal
Jan 25 2004
Carlos Santander B. wrote: [...]I know I can make work doing "return a.b();", but what would be the purpose of properties then?It also works with `return a.b + 0;'. Even the example in the docs does not compile, when the `+ 3' is deleted. So long.
Jan 26 2004








Manfred Nowak <svv1999 hotmail.com>