Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-106347

Build warns about QML code in C++ header with extension ".hh"

    XMLWordPrintable

Details

    • Windows
    • 9716c0187b (qt/qtdeclarative/dev) 9716c0187b (qt/tqtc-qtdeclarative/dev) 9e1ccb7617 (qt/tqtc-qtdeclarative/6.2) eb0fef688b (qt/qtdeclarative/6.4) eb0fef688b (qt/tqtc-qtdeclarative/6.4) 3c38cee25e (qt/qtdeclarative/6.3)

    Description

      We have our headers in files with extension ".hh". Now when we build, there is a warning:

       
      Class SomeClass is declared in SomeClass.hh, which appears not to be a header. The compilation of its registration to QML may fail.
       
      I could trace this to the file qtdeclarative/src/qmltyperegistrar/metatypesjsonprocessor.cpp, but it seems to be hard coded for certain extensions. Are there really problems with using other file extensions? I tried to find something about it in the documentation, but could not find anything (searched with google for "QML valid header file extension" and related searches).

      Attachments

        For Gerrit Dashboard: QTBUG-106347
        # Subject Branch Project Status CR V

        Activity

          People

            ulherman Ulf Hermann
            emmenlau Mario Emmenlauer
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: