Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-32422 convert StringData to std::string_view
  3. SERVER-32434

operator<<(ostream,StringData) ignores stream state.

    XMLWordPrintableJSON

Details

    • Icon: Sub-task Sub-task
    • Resolution: Fixed
    • Icon: Minor - P4 Minor - P4
    • 4.3.1
    • None
    • Portability
    • None
    • Fully Compatible

    Description

      ostream << std::setw(5) << expr

      behaves differently depending on whether expr is a std::string or a StringData.

      libc++'s operator<<(ostream, string_view) is complex, but accessible for reuse.
      https://github.com/llvm-mirror/libcxx/blob/0f25cd9/include/ostream#L714

      Attachments

        Activity

          People

            billy.donahue@mongodb.com Billy Donahue
            billy.donahue@mongodb.com Billy Donahue
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: