Re: Why do I get: cannot declare variable 'sc' ...
\ David Daney (31 Jul 2007)

2 msgWhy do I get: cannot declare variable ‘sc’ to b...
6 msgCompiler options for PowerPC
2 msgHow to change CR/LF to LF when compile gcc-4.1....
4 msgoperator new[] and operator delete[]
1 msgWhy am I seeing these warnings from system head...
3 msg-Bgroup?
3 msgGCC-3.3.6 and MIPS instruction 'EHB'
3 msgcr5-6 registers on i386
1 msgRe: WELCOME to gcc
25 msgRobust detection of endianness at compile time.
1 msgMESAJINIZ VAR
3 msgconfigure warning - test: too many arguments
1 msgProblem in loading DLL
3 msgright shift : strange behavior
2 msgTDF_DETAILS
6 msgInitialization of a static member of a template...
1 msgRe: dlopen() crash -gcc 3.4.6 20060404
1 msgRebuild GCC 4.2
3 msgUnrolling loops
Subject:Re: Why do I get: cannot declare variable 'sc' to be of abstract type...
Group:Gcc-help
From:David Daney
Date:31 Jul 2007


Johannes P. Schmidt wrote:
> Any recommendations on the best way to get the desired functionality? (C2 which is an I2 interface yet inherits the implementation from C1).
>
> One way that seems to work is to add "C2::a() { C1::a(); }", but it doesn't seem quite right.
>

Speaking as a non-C++ language lawyer, I think that is what we have to
do. I guess this reinforces the fact that C++ is not java.

David Daney

> Thanks,
>
> Johannes Schmidt
> jschmidt
> AOL IM: "Avtrex Jschmidt"
> cell 650-823-0462
> office 408-985-8600
> fax 408-516-8558
>
>> -----Original Message-----
>> From: John Love-Jensen [mailto:eljay]
>> Sent: Tuesday, July 31, 2007 9:57 AM
>> To: David Daney; MSX to GCC
>> Cc: Johannes P. Schmidt
>> Subject: Re: Why do I get: cannot declare variable Ś scą to be of abstract
>> type...
>>
>> Hi Dave,
>>
>>> I would think that I1::a() is not virtual because it is defined in the
>> super
>> class C1. What is going on here?
>>
>> I1::a was defined in super class C1 for the C1 half of the multiple
>> inheritance (via C2::C1::I2::defined a), but the I2 half's (via
>> C2::I2::I1::pure virtual a) a has not been concretely defined anywhere up
>> that inheritance chain.
>>
>> HTH,
>> --Eljay
>



© 2004-2008 readlist.com