Bug 1411

Summary: Inline specifiers for DoMakeAttributeAccessors
Product: ns-3 Reporter: Alex Afanasyev <alexander.afanasyev>
Component: coreAssignee: Mathieu Lacage <mathieu.lacage>
Status: RESOLVED FIXED    
Severity: normal CC: ns-bugs, pdbarnes, tomh
Priority: P5    
Version: ns-3-dev   
Hardware: All   
OS: All   
Attachments: Patch
Patch1
Patch2

Description Alex Afanasyev 2012-04-18 15:28:23 UTC
On Apple version of gcc, I was getting duplicate symbol link errors.  The following patch resolves the problem.
Comment 1 Alex Afanasyev 2012-04-18 15:28:39 UTC
Created attachment 1383 [details]
Patch
Comment 2 Alex Afanasyev 2013-04-26 18:10:43 UTC
Created attachment 1571 [details]
Patch1
Comment 3 Alex Afanasyev 2013-04-26 18:11:02 UTC
Created attachment 1572 [details]
Patch2
Comment 4 Peter Barnes 2014-02-21 01:29:55 UTC
Alex:  is this still needed?  Just the second attachment?

Could you please give the compiler version?
Comment 5 Alex Afanasyev 2014-02-21 03:59:24 UTC
I'm using clang (clang-500.2.79) on OSX 10.9.

In general, not having inline specifier there is wrong and should always have generated link errors...  I think the problem can be reproduced if in the same class two different attributes use the same getter/helper, but not really sure.
Comment 6 Mathieu Lacage 2014-02-21 04:58:23 UTC
(In reply to Alex Afanasyev from comment #5)
> I'm using clang (clang-500.2.79) on OSX 10.9.
> 
> In general, not having inline specifier there is wrong and should always
> have generated link errors...  I think the problem can be reproduced if in
> the same class two different attributes use the same getter/helper, but not
> really sure.

I can't find any reason not to merge this.

+1
Comment 7 Peter Barnes 2014-02-21 19:35:25 UTC
Patched r10625 16bbfc4cb29d
http://code.nsnam.org/ns-3-dev/rev/16bbfc4cb29d

(Included in patch for Bug 1411 by mistake)