diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2019-07-30 17:46:34 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2019-07-31 12:53:12 +0200 |
commit | 20aa2915b95ddad570ff1285c4de8a6f982c84b7 (patch) | |
tree | 71f0c7ed365479a7fc69f8aaa4ddf763781fd99e /unoidl | |
parent | ed96bbd34403277abbe37c06f0e74a3c09f54979 (diff) |
Improved loplugin:stringconstant (now that GCC 7 supports it): unoidl
Change-Id: I325e5f2d2e13c10c4d7e9110d41e959fca5e098c
Reviewed-on: https://gerrit.libreoffice.org/76632
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'unoidl')
-rw-r--r-- | unoidl/source/sourceprovider-parser.y | 52 | ||||
-rw-r--r-- | unoidl/source/unoidl-check.cxx | 6 |
2 files changed, 29 insertions, 29 deletions
diff --git a/unoidl/source/sourceprovider-parser.y b/unoidl/source/sourceprovider-parser.y index e9812570ed3c..c867c65551eb 100644 --- a/unoidl/source/sourceprovider-parser.y +++ b/unoidl/source/sourceprovider-parser.y @@ -82,27 +82,27 @@ void error(YYLTYPE location, yyscan_t yyscanner, OUString const & message) { OUString flagName(unoidl::detail::SourceProviderFlags flag) { switch (flag) { case unoidl::detail::FLAG_ATTRIBUTE: - return OUString("attribute"); + return "attribute"; case unoidl::detail::FLAG_BOUND: - return OUString("bound"); + return "bound"; case unoidl::detail::FLAG_CONSTRAINED: - return OUString("constrained"); + return "constrained"; case unoidl::detail::FLAG_MAYBEAMBIGUOUS: - return OUString("maybeambiguous"); + return "maybeambiguous"; case unoidl::detail::FLAG_MAYBEDEFAULT: - return OUString("maybedefault"); + return "maybedefault"; case unoidl::detail::FLAG_MAYBEVOID: - return OUString("maybevoid"); + return "maybevoid"; case unoidl::detail::FLAG_OPTIONAL: - return OUString("optional"); + return "optional"; case unoidl::detail::FLAG_PROPERTY: - return OUString("property"); + return "property"; case unoidl::detail::FLAG_READONLY: - return OUString("readonly"); + return "readonly"; case unoidl::detail::FLAG_REMOVABLE: - return OUString("removable"); + return "removable"; case unoidl::detail::FLAG_TRANSIENT: - return OUString("transient"); + return "transient"; default: assert(false && "this cannot happen"); for (;;) { std::abort(); } } @@ -3988,35 +3988,35 @@ OUString SourceProviderType::getName() const { } switch (type) { case unoidl::detail::SourceProviderType::TYPE_VOID: - return OUString("void"); + return "void"; case unoidl::detail::SourceProviderType::TYPE_BOOLEAN: - return OUString("boolean"); + return "boolean"; case unoidl::detail::SourceProviderType::TYPE_BYTE: - return OUString("byte"); + return "byte"; case unoidl::detail::SourceProviderType::TYPE_SHORT: - return OUString("short"); + return "short"; case unoidl::detail::SourceProviderType::TYPE_UNSIGNED_SHORT: - return OUString("unsigned short"); + return "unsigned short"; case unoidl::detail::SourceProviderType::TYPE_LONG: - return OUString("long"); + return "long"; case unoidl::detail::SourceProviderType::TYPE_UNSIGNED_LONG: - return OUString("unsigned long"); + return "unsigned long"; case unoidl::detail::SourceProviderType::TYPE_HYPER: - return OUString("hyper"); + return "hyper"; case unoidl::detail::SourceProviderType::TYPE_UNSIGNED_HYPER: - return OUString("unsigned hyper"); + return "unsigned hyper"; case unoidl::detail::SourceProviderType::TYPE_FLOAT: - return OUString("float"); + return "float"; case unoidl::detail::SourceProviderType::TYPE_DOUBLE: - return OUString("double"); + return "double"; case unoidl::detail::SourceProviderType::TYPE_CHAR: - return OUString("char"); + return "char"; case unoidl::detail::SourceProviderType::TYPE_STRING: - return OUString("string"); + return "string"; case unoidl::detail::SourceProviderType::TYPE_TYPE: - return OUString("type"); + return "type"; case unoidl::detail::SourceProviderType::TYPE_ANY: - return OUString("any"); + return "any"; case unoidl::detail::SourceProviderType::TYPE_SEQUENCE: assert(subtypes.size() == 1); return "[]" + subtypes.front().getName(); diff --git a/unoidl/source/unoidl-check.cxx b/unoidl/source/unoidl-check.cxx index ec7a3fbe7e4f..ff42573f7d1b 100644 --- a/unoidl/source/unoidl-check.cxx +++ b/unoidl/source/unoidl-check.cxx @@ -138,11 +138,11 @@ OUString showDirection( { switch (direction) { case unoidl::InterfaceTypeEntity::Method::Parameter::DIRECTION_IN: - return OUString("[in]"); + return "[in]"; case unoidl::InterfaceTypeEntity::Method::Parameter::DIRECTION_OUT: - return OUString("[out]"); + return "[out]"; case unoidl::InterfaceTypeEntity::Method::Parameter::DIRECTION_IN_OUT: - return OUString("[inout]"); + return "[inout]"; default: assert(false && "this cannot happen"); for (;;) { std::abort(); } } |