functions abstract?
Nalin Stefano 308885/IF
tikki@dei.unipd.it
Thu, 27 Nov 1997 11:02:25 +0100 (MET)
Hi Abdullah,
I had a similar problem a few days ago.
Define the find method as follows:
void find(short int & i)
{
cout << i;
}
it should compile correctly.
Bye,
Stefano Nalin
On Thu, 27 Nov 1997, Abdullah Bushnaq wrote:
> I am compiling an IDL file that has the following defintion:
>
> Interface Finder
> {
> void find (inout short i);
> };
>
> In my Finder_i.cc file that contains the implementation I have only
> defined the following:
>
> void find (short &i)
> {
> cout << i;
> }
>
> So obviously I don't have all of my code in, but whenever I try to
> compile the project I get the following error:
>
> libfind.cc: In function `int main(int, char **)':
> libfind.cc:31: cannot allocate an object of type `Finder_i'
> libfind.cc:31: since the following virtual functions are abstract:
> libfind.cc:31: void _sk_Finder::Find(short int &)
> make: *** [libfind.o] Error 1
>
>
> libfind is the file that initializes and starts the server, so it
> include the finder_i.cc file.
>
> I had this error before in a previous interface, unfortunately I was
> tweaking it and I solved the problem without actually realizing it, so
> in this case I am clueless. Is this error related to my C++ definition?
> or does my definition not comply with what I listed in the IDL file?
>
> Any hints would be appreciated,
>
> Abdullah Bushnaq
>