Bug 1411 - Inline specifiers for DoMakeAttributeAccessors
Inline specifiers for DoMakeAttributeAccessors
Status: RESOLVED FIXED
Product: ns-3
Classification: Unclassified
Component: core
ns-3-dev
All All
: P5 normal
Assigned To: Mathieu Lacage
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-04-18 15:28 UTC by Alex Afanasyev
Modified: 2014-02-21 19:35 UTC (History)
3 users (show)

See Also:


Attachments
Patch (2.07 KB, patch)
2012-04-18 15:28 UTC, Alex Afanasyev
Details | Diff
Patch1 (1.76 KB, patch)
2013-04-26 18:10 UTC, Alex Afanasyev
Details | Diff
Patch2 (1.37 KB, patch)
2013-04-26 18:11 UTC, Alex Afanasyev
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
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)