summaryrefslogtreecommitdiff
path: root/compilerplugins
diff options
context:
space:
mode:
authorLuboš Luňák <l.lunak@suse.cz>2013-03-21 16:17:07 +0100
committerLuboš Luňák <l.lunak@suse.cz>2013-03-28 18:01:00 +0100
commit9ab15ecc4f162cd6d8ce305f0d7ac064c1e1704c (patch)
tree525528c99e6d398a7a57fa77dd257b6792c719a4 /compilerplugins
parent2716dc0d4231f83fc2e1f3939bdce49c7b171e6c (diff)
-Wextra for compiler plugins
Change-Id: I246dcf1d2c099c510435d21f0dd47e3c098456f2
Diffstat (limited to 'compilerplugins')
-rw-r--r--compilerplugins/Makefile-clang.mk2
-rw-r--r--compilerplugins/clang/pluginhandler.cxx4
-rw-r--r--compilerplugins/clang/postfixincrementfix.cxx2
-rw-r--r--compilerplugins/clang/postfixincrementfix.hxx2
4 files changed, 5 insertions, 5 deletions
diff --git a/compilerplugins/Makefile-clang.mk b/compilerplugins/Makefile-clang.mk
index c762912b9e5d..ff92ba4fff0d 100644
--- a/compilerplugins/Makefile-clang.mk
+++ b/compilerplugins/Makefile-clang.mk
@@ -11,7 +11,7 @@
# You may occassionally want to override some of these
# Compile flags ('make CLANGCXXFLAGS=-g' if you need to debug the plugin)
-CLANGCXXFLAGS=-O2 -Wall -g
+CLANGCXXFLAGS=-O2 -Wall -Wextra -g
# The uninteresting rest.
diff --git a/compilerplugins/clang/pluginhandler.cxx b/compilerplugins/clang/pluginhandler.cxx
index 0d27ff67d0bb..7fa382c9d0ea 100644
--- a/compilerplugins/clang/pluginhandler.cxx
+++ b/compilerplugins/clang/pluginhandler.cxx
@@ -216,12 +216,12 @@ void PluginHandler::HandleTranslationUnit( ASTContext& context )
}
}
-ASTConsumer* LibreOfficeAction::CreateASTConsumer( CompilerInstance& Compiler, StringRef InFile )
+ASTConsumer* LibreOfficeAction::CreateASTConsumer( CompilerInstance& Compiler, StringRef )
{
return new PluginHandler( Compiler.getASTContext(), _args );
}
-bool LibreOfficeAction::ParseArgs( const CompilerInstance& CI, const vector< string >& args )
+bool LibreOfficeAction::ParseArgs( const CompilerInstance&, const vector< string >& args )
{
_args = args;
return true;
diff --git a/compilerplugins/clang/postfixincrementfix.cxx b/compilerplugins/clang/postfixincrementfix.cxx
index 9dac5168b1e3..6520ee8b1726 100644
--- a/compilerplugins/clang/postfixincrementfix.cxx
+++ b/compilerplugins/clang/postfixincrementfix.cxx
@@ -125,7 +125,7 @@ bool PostfixIncrementFix::canChangePostfixToPrefix( const CXXOperatorCallExpr* o
}
bool PostfixIncrementFix::canChangeInConditionStatement( const CXXOperatorCallExpr* op, const Expr* condition,
- const StmtParents& parents, int parent_pos )
+ const StmtParents& parents, unsigned int parent_pos )
{
// cannot be changed in condition, can be changed in statements
if( parent_pos == parents.size() - 1 )
diff --git a/compilerplugins/clang/postfixincrementfix.hxx b/compilerplugins/clang/postfixincrementfix.hxx
index beae8a76e520..7edb352c484d 100644
--- a/compilerplugins/clang/postfixincrementfix.hxx
+++ b/compilerplugins/clang/postfixincrementfix.hxx
@@ -30,7 +30,7 @@ class PostfixIncrementFix
void fixPostfixOperators( const Stmt* stmt, StmtParents& parents );
bool canChangePostfixToPrefix( const CXXOperatorCallExpr* op, StmtParents& parents, int parent_pos );
bool canChangeInConditionStatement( const CXXOperatorCallExpr* op, const Expr* condition,
- const StmtParents& parents, int parent_pos );
+ const StmtParents& parents, unsigned int parent_pos );
bool shouldDoChange( const Expr* op );
};