[cfe-commits] [patch] decltype in mem-initializers

David Blaikie dblaikie at gmail.com
Fri Dec 16 08:02:43 PST 2011


Bump and... hey, why not attach the patch.

On Wed, Dec 7, 2011 at 10:48 PM, David Blaikie <dblaikie at gmail.com> wrote:
> Another small/simple patch to add support for decltype in
> mem-initializers such as this:
>
> struct Base { Base(int); };
> struct Derived : Base {
>  Derived() : decltype(Base(1))(3) { // initializing base
>  }
>  Derived(int) : decltype(Derived())() { // forwarding ctor
>  }
> };
>
> Thanks again,
> - David
>
> [After this & the other patch I have out I should only have pseudo
> destructors left before we've finished N3031 (minor niggling leftover
> is that I need to go back & preclude the use of decltype in
> nested-name-specifiers that are used in declarator-ids, strangely -
> 8.3\1)]
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pr10127-base-init.diff
Type: text/x-diff
Size: 7885 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20111216/196fddfc/attachment.diff>


More information about the cfe-commits mailing list