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

Namespace with "enum" at its begining not being properly handled

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P2: Important
    • 6.4.0 Beta1
    • 6.0, 6.1, 6.2.1, 6.3
    • Build tools: moc
    • None
    • Windows 11, QtCreator IDE, CMake 3.22.0, Qt 6.2.1
    • Windows
    • 4e7f92bf0d (qt/qtbase/dev) 4e7f92bf0d (qt/tqtc-qtbase/dev)

    Description

      While attempting to migrate a project from Qt5 to Qt6, I encountered an unexpected behavior from the moc tool. If a namespace has the "enum" characters at its begining, for example, a namespace called "enumerations" the moc tool will strip the "enum" characters and generate a compile error.

      A minimum example to replicate the behavior can be found at: https://pastebin.com/PuxaV0e6

      And the corrupted moc output: https://pastebin.com/Ujs1B8W3

       

       

      Attachments

        Activity

          People

            fabiankosmale Fabian Kosmale
            hlsm Hudson Luiz Silva de Miranda
            Votes:
            2 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: