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

operator* for nested template class has no highlighting

    XMLWordPrintable

Details

    • 7c74482ad361ee81f87c8ed039b789807934f0e7

    Description

      struct Foo { int foo; };
      
      template<class T>
      struct Outer
      {
        struct Nested
        {
          const T &operator*() { return t; }
          T t;
        };
      };
      
      void bug()
      {
        Outer<Foo>::Nested nested;
        (*nested).foo; // Not highlighted, can't run find usages
      }

      Placing the caret on this line highlights both appearances of foo (the declaration and the usage) but doesn't allow Find Usages.

      Running Find Usages on the declaration does find this usage.

      Attachments

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

        Activity

          People

            orgads Orgad Shaneh
            orgads Orgad Shaneh
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes