diff options
author | Shinichiro Hamaji <shinichiro.hamaji@gmail.com> | 2015-07-03 16:26:15 +0900 |
---|---|---|
committer | Shinichiro Hamaji <shinichiro.hamaji@gmail.com> | 2015-07-03 16:26:15 +0900 |
commit | 8d503017f7fdb54fb6b522e0415751d7e172662f (patch) | |
tree | 52b672fd7084f7cce9312070cddf4d3ba0c33d22 | |
parent | fad83c5bcd2c0a84a8408717acfc795d7518b4e3 (diff) | |
download | android_build_kati-8d503017f7fdb54fb6b522e0415751d7e172662f.tar.gz android_build_kati-8d503017f7fdb54fb6b522e0415751d7e172662f.tar.bz2 android_build_kati-8d503017f7fdb54fb6b522e0415751d7e172662f.zip |
[C++] Suppress warnings
-rw-r--r-- | dep.cc | 2 | ||||
-rw-r--r-- | eval.cc | 1 | ||||
-rw-r--r-- | exec.cc | 2 | ||||
-rw-r--r-- | log.h | 3 |
4 files changed, 6 insertions, 2 deletions
@@ -399,7 +399,7 @@ class DepBuilder { return rule.get(); } - DepNode* BuildPlan(Symbol output, Symbol needed_by) { + DepNode* BuildPlan(Symbol output, Symbol needed_by UNUSED) { LOG("BuildPlan: %s for %s", output.c_str(), needed_by.c_str()); @@ -199,6 +199,7 @@ void Evaluator::EvalIf(const IfAST* ast) { } default: CHECK(false); + abort(); } const vector<AST*>* asts; @@ -44,7 +44,7 @@ class Executor { : ce_(ev) { } - void ExecNode(DepNode* n, DepNode* needed_by) { + void ExecNode(DepNode* n, DepNode* needed_by UNUSED) { if (done_[n->output]) return; done_[n->output] = true; @@ -28,6 +28,9 @@ using namespace std; extern bool g_log_no_exit; extern string* g_last_error; +// Useful for logging-only arguments. +#define UNUSED __attribute__((unused)) + #ifdef NOLOG #define LOG(args...) #else |