<html>
    <head>
      <base href="https://bugs.llvm.org/">
    </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 - No completion for incomplete type alias"
   href="https://bugs.llvm.org/show_bug.cgi?id=36499">36499</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>No completion for incomplete type alias
          </td>
        </tr>

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

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

        <tr>
          <th>Hardware</th>
          <td>PC
          </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>libclang
          </td>
        </tr>

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

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

        <tr>
          <th>CC</th>
          <td>klimek@google.com, llvm-bugs@lists.llvm.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>libclang seems to have added support for completion of incomplete types, but a
trivial type alias cause it to break:

template <typename T> struct A { void foo(); };

template <typename T> using B = A<T>;

template <typename T> struct C {
    A<T> a;
    B<T> b;
    C() {
        // a. completes
        // b. doesn't complete
    }
};

Completion for a. gives:

❯❯❯ c-index-test -code-completion-at=sample.cpp:9:11 sample.cpp                 
StructDecl:{TypedText A}{Text ::} (75)
CXXMethod:{ResultType void}{TypedText foo}{LeftParen (}{RightParen )} (34)
NotImplemented:{TypedText template} (40)
Completion contexts:
Dot member access

Completion for b. gives:

❯❯❯ c-index-test -code-completion-at=sample.cpp:9:11 sample.cpp
Completion contexts:
Dot member access</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>