From 8332d6d8200e8ca1f22dd98d9373efd5a431d09c Mon Sep 17 00:00:00 2001 From: Noel Date: Wed, 25 Nov 2020 08:14:07 +0200 Subject: loplugin:stringviewparam include comparisons with string literals Change-Id: I8ba1214500dddaf413c506a4b82f43d63cda804b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106559 Tested-by: Jenkins Reviewed-by: Noel Grandin --- unoidl/source/unoidlprovider.cxx | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'unoidl') diff --git a/unoidl/source/unoidlprovider.cxx b/unoidl/source/unoidlprovider.cxx index 4e85ad795825..9450cab33428 100644 --- a/unoidl/source/unoidlprovider.cxx +++ b/unoidl/source/unoidlprovider.cxx @@ -166,13 +166,13 @@ struct Memory64 { } }; -bool isSimpleType(OUString const & type) { - return type == "void" || type == "boolean" || type == "byte" - || type == "short" || type == "unsigned short" || type == "long" - || type == "unsigned long" || type == "hyper" - || type == "unsigned hyper" || type == "float" || type == "double" - || type == "char" || type == "string" || type == "type" - || type == "any"; +bool isSimpleType(std::u16string_view type) { + return type == u"void" || type == u"boolean" || type == u"byte" + || type == u"short" || type == u"unsigned short" || type == u"long" + || type == u"unsigned long" || type == u"hyper" + || type == u"unsigned hyper" || type == u"float" || type == u"double" + || type == u"char" || type == u"string" || type == u"type" + || type == u"any"; } // For backwards compatibility, does not strictly check segments to match -- cgit