www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - Method not implemented (repost)

reply Ant <Ant_member pathlink.com> writes:
windows XP, dmd 0.102

I have

interface TupleIF;

class Tuple : TupleIF;

class DBTuple : Tuple;

Tuple  implements all the methods of interface TupleIF.

the compiler complains:
dool\sql\DBTuple.d(10): class DBTuple interface function TupleIF.columnCount
isn't implemented

Ant
Oct 14 2004
parent reply Regan Heath <regan netwin.co.nz> writes:
On Fri, 15 Oct 2004 02:23:11 +0000 (UTC), Ant <Ant_member pathlink.com> 
wrote:
 windows XP, dmd 0.102

 I have

 interface TupleIF;

 class Tuple : TupleIF;

 class DBTuple : Tuple;

 Tuple  implements all the methods of interface TupleIF.

 the compiler complains:
 dool\sql\DBTuple.d(10): class DBTuple interface function 
 TupleIF.columnCount
 isn't implemented
I tried: interface IF { void one(); void two(int i); } class A : IF { void one() { } void two(int i) { } } class B : A { } void main() { A a = new A(); B b = new B(); A c = new B(); } and got no error, I'm guessing your source is a wee bit more complex. Are mixins involved? Can you post the source or tell me where to get it. Regan -- Using M2, Opera's revolutionary e-mail client: http://www.opera.com/m2/
Oct 14 2004
parent Ant <Ant_member pathlink.com> writes:
In article <opsfv4bu0b5a2sq9 digitalmars.com>, Regan Heath says...
I tried:

interface IF {
   void one();
   void two(int i);
}

class A : IF {
   void one() {
   }
   void two(int i) {
   }
}

class B : A {
}

void main()
{
   A a = new A();
   B b = new B();
   A c = new B();
}

and got no error, I'm guessing your source is a wee bit more complex. Are 
mixins involved? Can you post the source or tell me where to get it.
Obviously I tried that before posting. I would like to be able to do more to help finding this. and it's not just the source, you need to compile them in just the wrong way. On the particular case I was compiling each package at a time and I got a differente error (something not found on the library) so I tried to compile every thing in one batch and I got that error. I'll post every thing I got over the weekend (DUI tests now compile and run (almost all) on both windows in linux. I'm just building an easy install for windows) What I'll do know is to try to group my modules compilation until both errors go away... :( I would like to be able to do more to find these errors. here are (from memory) the errors I got on windows on these last few days, I had all these on linux also and was able to workaround in most of the cases: - interface methods not implemented (this case-couldn't work around on linux) - methods and classes not added to the libs (never on linux) - bad code generated resulting in segfault - forward references - private imports available out of scope - imports not private on phobos all these were reported before. all these are difficult to reproduce in small examples, but I think it's demonstrated they are problems with dmd and not the user code. these seem to be small anoyances on small examples, tests and prof of concept programs but they will cripple dmd for real world use and are big headeachs on larger applications. Ant
Oct 15 2004