Details
-
Bug
-
Resolution: Done
-
P3: Somewhat important
-
Qt Creator 4.8.0
-
None
-
-
83fb81df35a62e6366689f2644281605ea134128 (qt-creator/qt-creator/4.8)
Description
QT Creator currently treats inline headers (*.inl) as source files, not as headers.
But that doesn't make sense. An .inl file is a header. It contains inline code and especially template definitions. It is used by including it in the main header of a module and through this compiled in all translation units using its definitions. It can not be compiled by its own as a source file.
This means the MIME definition is wrong. It should be registered as header file not as source file so adding an .inl file to a project adds it to the right group of files.
Since there is no convention, people use different extensions like tpp, tcc, txx, ipp, icc, etc. It may be that Qt Creator supports some of these extensions as well suffering from the same wrong MIME definition.
Also handling of projects with .inl headers is a bit difficult. Qt Creator switches pretty fine between hpp and cpp when pressing F4 but it doesn't get the idea of a secondary .inl header. It would be great if F4 would cycle between all three files in case an .inl exist of the same name.
Finally (but not that important) it would be nice to have refactoring support for such files.
Attachments
For Gerrit Dashboard: QTCREATORBUG-21736 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
248466,2 | CppTools: Fix categorization of *.inl, *.tpp, and similar | 4.8 | qt-creator/qt-creator | Status: MERGED | +2 | 0 |