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

Add QByteArrayView::toHex() & toBase64()

    XMLWordPrintable

Details

    • Suggestion
    • Resolution: Unresolved
    • P3: Somewhat important
    • None
    • 6.8
    • None
    • All

    Description

      QByteArrayView has convenient toInt(), toFloat(), etc, that can be used on sliced() "non-copy" of byte array.

      But toHex() is missing though, and it might help to save even bigger copies.

      For example, some real code (Qt5):

      imei = m_data.mid(4, 8).toHex();

      could be converted to:

      imei = QByteArrayView{m_data}.sliced(4, 8).toHex();

      to save redundant copy.

       

      Attachments

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

        Activity

          People

            cnn Qt Core & Network
            vdargis_at_uab_styritrade Vincas Dargis
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes