[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    Re: is const BC?
From:       Nicolas Brodu <nicolas.brodu () free ! fr>
Date:       2000-07-03 21:42:12
[Download RAW message or body]

Stephan Kulow wrote:
> 
> Hi!
> 
> I would suggest the following patch for kpanelapplet.h
> but I don't know if this is BC

I don't think so:

-- toto.cc
class A
{
public:
void foo();
};

void A::foo()
{
}

-- main.cc
class A
{
public:
   void foo() const;
};

main()
{
	A a;
	a.foo();
}

bowling:~/tmp>g++ -c toto.cc -o toto.o
bowling:~/tmp>g++ main.cc toto.o -o main
/var/tmp/ccbJa42H1.o: In function `main':
/var/tmp/ccbJa42H1.o(.text+0xc): undefined reference to `A::foo(void) const'
zsh: 17335 exit 1     g++ main.cc toto.o -o main


But the functions in the patch should be made const still, I think.

Cheers,
Nicolas
-- 
WYSIWYG: You can't get what you don't see. --> Use LaTeX!

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic