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

Use dedicated enum ConfigurationKey instead int as function parameter

    XMLWordPrintable

Details

    • Suggestion
    • Resolution: Done
    • Not Evaluated
    • 6.2.0 Alpha, 6.2
    • 5.15.2
    • SerialBus: CAN Bus
    • None
    • All
    • 227060f8c17aaf90fe542ad6079a6badaf410a0d (qt/qtserialbus/dev)

    Description

      In qcanbusdevice.h, we have the following prototypes:

      virtual void setConfigurationParameter(int key, const QVariant &value);
      QVariant configurationParameter(int key) const;
      QVector<int> configurationKeys() const; 

      Was there a reason to use int for the key, and not the dedicated enum ConfigurationKey?

      Do we want to change that for Qt 6?

      If the enum is kept as-is (i.e. no enum class), it should be even source compatible with existing code.

      Attachments

        Issue Links

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

          Activity

            People

              aha_1980 André Hartmann
              aha_1980 André Hartmann
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes