[llvm-bugs] [Bug 25182] Typedef return type + Fully Qualified name for a member function causes error in out-of-line definition

via llvm-bugs llvm-bugs at lists.llvm.org
Wed Oct 14 15:23:05 PDT 2015


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

Richard Smith <richard-llvm at metafoo.co.uk> changed:

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

--- Comment #1 from Richard Smith <richard-llvm at metafoo.co.uk> ---
Whenever an identifier is followed by a ::, the pair of tokens is parsed as a
nested-name-specifier, and the program is ill-formed if the name before the ::
does not name a namespace, class, or enumeration. See [basic.lookup.qual]p1 and
http://wg21.link/cwg1828.

So, your example fails to parse because

  test_t::S::f

... is not a valid name. (GCC has a bug / extension where it accepts such
invalid code.)

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20151014/9da2ee85/attachment.html>


More information about the llvm-bugs mailing list