Simplify a std::string_view construction
commit90f872b4c9eac6ea1955876ff292a962f95577dd
authorStephan Bergmann <sbergman@redhat.com>
Fri, 18 Jun 2021 13:18:26 +0000 (18 15:18 +0200)
committerStephan Bergmann <sbergman@redhat.com>
Fri, 18 Jun 2021 20:17:06 +0000 (18 22:17 +0200)
treef31094d4769db6a0b0e53e12602dbf4af753a21d
parent568fba4a439f39aadeeb1bcd3603ef4efe9700da
Simplify a std::string_view construction

...and combine three calls to SvStream::WriteOString into one.

Despite its name, SvStream::WriteOString takes a std::string_view, but which
cannot be constructed from a u8"..." char8_t string literal.  Besides the
OStringLiteral detour, other fixes could have been a
reinterpret_cast<char const *> (but which would have defeated constexpr'ness of
the std::string_view construction) or a plain "..." char string literal with
the UTF-8 encoding of \uFEFF spelled out as \0xEF\xBB\xBF.

Change-Id: I029f061134381a67516cbc4b0479942684c80c20
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117461
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
vcl/source/pdf/XmpMetadata.cxx