Actions

icon Post
text/html Subscribe
text/html Unsubscribe

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [cxx-abi-dev] Mangling late-specified return types/decltype


  • To: "cxx-abi-dev@xxxxxxxxxxxxxxxx" <cxx-abi-dev@xxxxxxxxxxxxxxxx>
  • Subject: Re: [cxx-abi-dev] Mangling late-specified return types/decltype
  • From: Jason Merrill <jason@xxxxxxxxxx>
  • Date: Wed, 17 Sep 2008 11:49:01 -0700

More generally, within decltype/sizeof/alignof we aren't interested in the value of a type, only the type itself, so there's a lot of information in the expression which is irrelevant. Within decltype, *(T*)0 and t are equivalent: both are T lvalues. T(42) and T() and T(a,b,0932) are also equivalent: all are T rvalues.

In all these cases, it seems like we could replace these expressions with "lvalue placeholder" (sT) or "rvalue placeholder", and simplify decltype (T lvalue placeholder) to T so we don't have to mangle as much random expression gunk.

Otherwise we still need to establish a mangling for T(more,than,one,arg).

Jason