[cxx-abi-dev] lambda ABI inline function ODR compatibility issue

John McCall rjmccall at apple.com
Fri Jan 18 19:05:29 UTC 2013


On Jan 18, 2013, at 10:51 AM, Michael Wong <michaelw at ca.ibm.com> wrote:
> I should explain a little more my motivation for supporting #3. I think #1 would require significant ABI committee work and #2 would require significant Standard committee (and implementation) work.

That it might require us to do a modest amount of work isn't really a compelling
reason to oppose a proposal.  The good reason to oppose proposal #2 (banning
lambdas in weak-linkage functions) is that it takes away functionality for very
obscure reasons, and the good reason to oppose proposal #1 (guaranteeing a
layout) is that it's a potentially significant performance restriction imposed for,
again, fairly obscure reasons.

Reasons to oppose #3 (internal linkage) include a) that it introduces a new
source of undefined behavior and b) that it somewhat complicates the language
design of the feature, albeit in a way that feels fairly natural given the anonymity
of the type.  I'm comfortable with both of these, but we should admit them.

John.


More information about the cxx-abi-dev mailing list