<html>
    <head>
      <base href="https://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 --- - rejects-valid on dependent type in exception specification of overriding function"
   href="https://llvm.org/bugs/show_bug.cgi?id=22950">22950</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>rejects-valid on dependent type in exception specification of overriding function
          </td>
        </tr>

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

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

        <tr>
          <th>Hardware</th>
          <td>All
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>All
          </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>hstong@ca.ibm.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>In handling C++03 subclause 15.4 [except.spec] paragraph 3, it seems to me that
an exception-specification containing a dependent type-id should not be checked
to see if it only allows exceptions that are allowed by another (non-empty)
exception-specification while processing the template definition (versus an
instantiation).

### SOURCE (<stdin>):
struct A {
   virtual void foo() throw(int) = 0;
};

template <typename T>
struct B : A {
   virtual void foo() throw(T);
};


### COMPILER INVOCATION:
clang -fsyntax-only -x c++ -


### ACTUAL OUTPUT:
<stdin>:7:17: error: exception specification of overriding function is more lax
than base version
   virtual void foo() throw(T);
                ^
<stdin>:2:17: note: overridden virtual function is here
   virtual void foo() throw(int) = 0;
                ^
1 error generated.


### EXPECTED OUTPUT:
No errors.


### COMPILER VERSION INFO:
clang version 3.7.0 (trunk 232637)
Target: x86_64-unknown-linux-gnu
Thread model: posix
Found candidate GCC installation:
/usr/local/gcc-4.8.2/lib/gcc/x86_64-unknown-linux-gnu/4.8.2
Selected GCC installation:
/usr/local/gcc-4.8.2/lib/gcc/x86_64-unknown-linux-gnu/4.8.2
Candidate multilib: .;@m64
Selected multilib: .;@m64</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>