[cfe-dev] When does ~decltype(expr) make sense ?

Manasij Mukherjee manasij7479 at gmail.com
Sun Feb 22 14:33:22 PST 2015


>
> 5.1.1 [expr.prim.general] in paragraph 8 states that "The form ~
> decltype-specifier also denotes the destructor, but it shall not be used as
> the unqualified-id in a qualified-id."
>
> I implemented this a while ago, but it looks like (r146155) it was for
> expressions (x.~decltype(*x)(), for example) not necessarily for dtor
> declarations.
>
> I do not clearly understand what this sentence implies.
Could you elaborate?

Also, if the meaning is as you interpreted it, what is the rationale for
allowing x.~decltype(*x)() ?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20150223/20cbf1f5/attachment.html>


More information about the cfe-dev mailing list