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

QString: add missing STL-style assign(It, It) with value_type_t<It> in {char, char8_t} (i.e. UTF-8)

    XMLWordPrintable

Details

    • 13
    • 15ff5bafa (dev), cbaecba8d (6.6), 0d7a4e5e9 (6.5), edcb8e901 (dev), ff0c19168 (6.5), 70eab2cfd (6.6), 016addc20 (dev)
    • Foundation Sprint 84, Foundation Sprint 85, Foundation Sprint 86, Foundation Sprint 87, Foundation Sprint 88, Foundation Sprint 89, Foundation Sprint 90, Foundation Sprint 91, Foundation Sprint 92

    Description

      This is a follow-up task on QTBUG-106198.

      QString::assign() can currently handle value_type's that correspond to UTF-16 and UTF-32-encoded data. It can not handle (SFINAEs out) UTF-8-encoded data, as that requires to keep state between input code points, and qstringconverter.h is currently not #include'able from qstring.h. The contiguous_iterator case is actually handled by the QAnyStringView overload, and would work if not SFINAEd out. It's SFINAEd out to keep the condition (and docs) sane. It's the non-contiguous_iterator case that's the problem.

      Acceptance criteria:

      • QString::assign() accepts input_iterator sequences
      • correctly decodes UTF-8 to UTF-16

      Attachments

        Issue Links

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

          Activity

            People

              dennisoberst Dennis Oberst
              mmutz Marc Mutz
              Vladimir Minenko Vladimir Minenko
              Alex Blasche Alex Blasche
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: