|
-
September 23rd, 2009, 12:00 PM
#1
multiple definition of a function
I want to extend an open source project. Inside the project there is a header file named inet.h which has the following structure:
#ifndef __IPV4UNDERLAYCONFIGURATOR_H__
#define __IPV4UNDERLAYCONFIGURATOR_H__
class foo{
method1();
}
bool method3(){
//method implementation
};
#endif
I have created a header file name extinet.h within which I include intet.h and it looks like this
[...]
include "inet.h"
class foo2 ublic foo{};
[...]
When I try to compile the project I get a multiple definition error for method3. Is there a way to avoid this error without modifying inet.h (e.g, without declaring method3 to be inline)?
Thanks
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|