[cxx-abi-dev] Mangling C++0x Lambdas

Doug Gregor doug.gregor at gmail.com
Mon Dec 15 18:00:53 UTC 2008


On Mon, Dec 15, 2008 at 7:50 AM, David Vandevoorde <daveed at edg.com> wrote:
> Has anyone on this list already implemented C++0x lambdas and chosen a
> mangling scheme for them?

The prototype GCC implementation had a mangling scheme, but it won't
work in the general case.

> (We think a mangling convention is needed because they can appear in inline
> function bodies or determine template argument types.)

Agreed. They can also appear in the initialization of variables at
namespace scope, e.g.,

  struct X {
    template<typename T> X(T);
  };
  X x = [](int x) -> int { return x; }

  - Doug



More information about the cxx-abi-dev mailing list