<html>
    <head>
      <base href="http://llvm.org/bugs/" />
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW --- - clang thinks class is incomplete in exception specification"
   href="http://llvm.org/bugs/show_bug.cgi?id=20414">20414</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>clang thinks class is incomplete in exception specification
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>clang
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>trunk
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>Macintosh
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>MacOS X
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>normal
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>C++
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>unassignedclangbugs@nondot.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>alexandermbock@gmail.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>dgregor@apple.com, llvmbugs@cs.uiuc.edu
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr></table>
      <p>
        <div>
        <pre>struct B;

struct A {
    B& operator->();
    int foo;
};

struct B {
    auto operator->() -> A*;
    auto f() throw(decltype(A()->foo)) -> void;
};


My understanding is that per 9.2 [class.mem], B should be considered complete
inside of the exception specification, and this code should be valid. gcc (4.8)
and edg-based compilers allow this example without complaint; clang complains:

error: incomplete definition of type 'B'
        auto f() throw(decltype(A()->foo)) -> void;
                                ^~~

note: definition of 'B' is not complete until the closing '}'
struct B {
       ^


clang version 3.5.0 (trunk 213749)
Target: x86_64-apple-darwin14.0.0
Thread model: posix</pre>
        </div>
      </p>
      <hr>
      <span>You are receiving this mail because:</span>
      
      <ul>
          <li>You are on the CC list for the bug.</li>
      </ul>
    </body>
</html>