convert some plugins to use the sharedplugin infrastructure

Change-Id: I690d9df436abdadc51a6d3f7df686a2e37f79f73
Reviewed-on: https://gerrit.libreoffice.org/75624
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
This commit is contained in:
Noel Grandin
2019-07-15 12:14:34 +02:00
parent fd55c09eba
commit fc1b213d15
16 changed files with 540 additions and 53 deletions

View File

@@ -5,6 +5,8 @@
* Based on LLVM/Clang.
*
*/
#ifndef LO_CLANG_SHARED_PLUGINS
#include "plugin.hxx"
/*
@@ -22,7 +24,7 @@ class StaticAnonymous
public:
explicit StaticAnonymous( const InstantiationData& data );
virtual void run() override;
bool VisitFunctionDecl( FunctionDecl* func );
bool VisitFunctionDecl( const FunctionDecl* func );
};
@@ -37,7 +39,7 @@ void StaticAnonymous::run()
}
bool StaticAnonymous::VisitFunctionDecl( FunctionDecl* func )
bool StaticAnonymous::VisitFunctionDecl( const FunctionDecl* func )
{
if( ignoreLocation( func ) )
@@ -59,8 +61,10 @@ bool StaticAnonymous::VisitFunctionDecl( FunctionDecl* func )
}
// Register the plugin action with the LO plugin handling.
static Plugin::Registration< StaticAnonymous > X( "staticanonymous",true);
static Plugin::Registration< StaticAnonymous > staticanonymous("staticanonymous");
} // namespace
#endif // LO_CLANG_SHARED_PLUGINS
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */