[cxx-abi-dev] Key functions and templates

Zbigniew Sarbinowski zibi at ca.ibm.com
Tue Feb 23 04:58:01 UTC 2010


Lawrence Crowl <crowl at google.com> wrote on 02/22/2010 06:45:25 PM:
> One could argue that it is not "always declared inline" because
> there is not inline declaration in t2.cpp.  That interpretation is
> consistent with the standard, so I wouldn't want to rule it out.

Yeap, you're right but other interpretation could argue that since
this function is considered inline but not used in t1.cpp why would
we want to generate its body in this CU?

Your argument also shows that this is invalid since no inline function
used in t2.cpp should be defined either within the same CU or elsewhere as
no
inline function.  This comes down to inconsistency of marking this function
as inline.

If this function is inline in t1.cpp but not used nothing is stopping to
not generate
this function since we know that if it's used elsewhere (like in t2.cpp) it
should also be
defined there.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://sourcerytools.com/pipermail/cxx-abi-dev/attachments/20100222/9a3d9c0d/attachment.html>


More information about the cxx-abi-dev mailing list