https://llvm.org/bugs/show_bug.cgi?id=24904

Richard Smith <richard-l...@metafoo.co.uk> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |richard-l...@metafoo.co.uk
         Resolution|---                         |INVALID

--- Comment #1 from Richard Smith <richard-l...@metafoo.co.uk> ---
C++ [expr.const]p2:

"A conditional-expression e is a core constant expression unless the evaluation
of e, following the rules of the abstract machine (1.9), would evaluate one of
the following expressions:
(2.1)
 — this (5.1.2), except in a constexpr function or a constexpr constructor that
is being evaluated as part of e;"

So while "B::b()" is a constant expression, "this->b()" is not; clang is
correct to reject this.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to