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

Incorrect function argument type highlighting with attributes

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • Not Evaluated
    • None
    • Qt Creator 9.0.1
    • C/C++/Obj-C++ Support
    • Kubuntu 22.04
    • Linux/X11

    Description

      In the following piece of code:

      #include <string_view>
      
      class test
      {
      public:
      	__attribute__((__visibility__("default")))
      	explicit test(std::string_view arg);
      };
      

      the `string_view` is not colored as a type (blue) but as a regular text (black). If you comment the `__attribute__` line, the expected coloring restores.

      This is with clangd enabled in QtCreator settings.

      QtCreator version is 9.0.2 pre-release build from revision https://code.qt.io/cgit/qt-creator/qt-creator.git/log/?id=9256340e5bed3a57b8f4cdca36659348211697ad.

      Attachments

        Activity

          People

            kandeler Christian Kandeler
            lastique Andrey Semashev
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: