http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49003
--- Comment #3 from Jonathan Wakely <redi at gcc dot gnu.org> 2011-05-16 14:48:13 UTC --- A simpler test for DR 1207 being implemented is: struct A { auto a() const -> decltype(this) { return this; } }; nc.cc:2:32: error: invalid use of 'this' at top level nc.cc:2:32: error: invalid use of 'this' at top level The late-specified return type should be accepted with the same type as the return statement's expression i.e. const A*