Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-28114

Type hierarchy does not traverse templated inheritance, missing children

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: P3: Somewhat important P3: Somewhat important
    • None
    • Qt Creator 7.0.2, Qt Creator 8.0.1
    • C/C++/Obj-C++ Support

      The type hierarchy of classes inherited through template parameters is incomplete.

      class A {};
      class B : A {};
      class MixinBase {};
      template<typename Parent>
      class Mixin : Parent, MixinBase {};
      class C : Mixin<A> {};
      

      Requesting the type hierarchy of A should show Mixin<A> and under that C, because C is also an A, which is probably the most important piece of information you expect to get from this feature ("which subclasses of this class exist?").

      Similar thing with base classes. Viewing the type hierarchy of C shows Mixin<T> as a base, but not the actual T. It does show MixinBase as a parent, but misses the templatized Parent=A, which unfortunately makes the feature quite unreliable in C++.

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            kandeler Christian Kandeler
            ruben.vanboxem Ruben Van Boxem
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:

                There are no open Gerrit changes