2012-10-09 14:50:19 +02:00
|
|
|
/*
|
|
|
|
* This file is part of the LibreOffice project.
|
|
|
|
*
|
|
|
|
* Based on LLVM/Clang.
|
|
|
|
*
|
|
|
|
* This file is distributed under the University of Illinois Open Source
|
|
|
|
* License. See LICENSE.TXT for details.
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef UNUSEDVARIABLECHECK_H
|
|
|
|
#define UNUSEDVARIABLECHECK_H
|
|
|
|
|
2012-10-15 15:36:25 +02:00
|
|
|
#include "plugin.hxx"
|
2012-10-09 14:50:19 +02:00
|
|
|
|
|
|
|
namespace loplugin
|
|
|
|
{
|
|
|
|
|
|
|
|
class UnusedVariableCheck
|
|
|
|
: public RecursiveASTVisitor< UnusedVariableCheck >
|
2012-10-09 16:27:25 +02:00
|
|
|
, public Plugin
|
2012-10-09 14:50:19 +02:00
|
|
|
{
|
|
|
|
public:
|
2013-03-21 16:42:10 +01:00
|
|
|
explicit UnusedVariableCheck( CompilerInstance& compiler );
|
2013-02-02 17:45:18 +01:00
|
|
|
virtual void run();
|
2012-10-13 17:38:58 +02:00
|
|
|
bool VisitVarDecl( VarDecl* var );
|
2012-10-09 14:50:19 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
} // namespace
|
|
|
|
|
|
|
|
#endif // UNUSEDVARIABLECHECK_H
|