From 20c6dfde1dff22de7d38ecea00bcf75aa21a1694 Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Mon, 21 Oct 2019 19:27:12 +0200 Subject: [PATCH] There doesn't need to be a TemplateSpecializationType here On both macOS (libc++) and Windows (MSVC standard library), compilerplugins/clang/test/getstr.cxx failed four tests without this fix: > error: 'error' diagnostics expected but not seen: > File compilerplugins/clang/test/getstr.cxx Line 29: suspicious use of 'getStr' on an object of type 'rtl::OUStringBuffer'; the result is implicitly cast to a void pointer in a call of 'operator <<' [loplugin:getstr] > File compilerplugins/clang/test/getstr.cxx Line 30: directly use object of type 'S' (aka 'rtl::OString') in a call of 'operator <<', instead of calling 'getStr' first [loplugin:getstr] > File compilerplugins/clang/test/getstr.cxx Line 34: suspicious use of 'getStr' on an object of type 'rtl::OUStringBuffer'; the result is implicitly cast to a void pointer in a call of 'operator <<' [loplugin:getstr] > File compilerplugins/clang/test/getstr.cxx Line 35: directly use object of type 'rtl::OString' in a call of 'operator <<', instead of calling 'getStr' first [loplugin:getstr] Change-Id: I65406d3d84bb5a89df44c8fd665b6e38d19f38c7 Reviewed-on: https://gerrit.libreoffice.org/81266 Tested-by: Jenkins Reviewed-by: Stephan Bergmann --- compilerplugins/clang/getstr.cxx | 1 - 1 file changed, 1 deletion(-) diff --git a/compilerplugins/clang/getstr.cxx b/compilerplugins/clang/getstr.cxx index 15f340296bea..aba53bd6e2e5 100644 --- a/compilerplugins/clang/getstr.cxx +++ b/compilerplugins/clang/getstr.cxx @@ -70,7 +70,6 @@ public: } assert(expr->getNumArgs() == 2); if (!loplugin::TypeCheck(expr->getArg(0)->getType()) - .TemplateSpecializationClass() .ClassOrStruct("basic_ostream") .StdNamespace()) //TODO: check template args {