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

String literal generated by moc hits compiler imposed limits

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P2: Important
    • Resolution: Done
    • Affects Version/s: 5.2.0
    • Fix Version/s: 5.5.0
    • Component/s: Build tools: moc
    • Labels:
      None

      Description

      The moc generates a single string literal that is stored into the 'stringdata' member of the 'qt_meta_stringdata_<namespace>_<class>_t' structure. If a class has a large number of enums constants, properties, then this string literal grows large enough that it hits the compiler limits.

      For instance, with Microsoft Visual C++ 9.0 compiler, the limit is 65535 for a single string literal.

        Attachments

        1. moc_sample.cpp
          926 kB
        2. sample.h
          604 kB
        For Gerrit Dashboard: QTBUG-36500
        # Subject Branch Project Status CR V

          Activity

            People

            • Assignee:
              nierob Nierob
              Reporter:
              balpeck@yahoo.com Balaji Ramachandran
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Gerrit Reviews

                There are no open Gerrit changes