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

QFlags doesn't support large (> sizeof(int)) enums

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P2: Important
    • None
    • 6.5
    • Core: Other
    • None

    Description

      First caught in https://codereview.qt-project.org/c/qt/qtbase/+/35764, with plans to introduce support in 5.1. Then we removed indications of that plan in https://codereview.qt-project.org/c/qt/qtbase/+/54720 (not sure why, though).

      Unless we need a guarantee that QFlags<T> is the same size for all T, using underlying_type<T> instead of int for sizeof(T) > sizeof(int) seems like an easy way out.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            cnn Qt Core & Network
            fabiankosmale Fabian Kosmale
            Vladimir Minenko Vladimir Minenko
            Alex Blasche Alex Blasche
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes