Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(453)

Unified Diff: tools/gn/setup.cc

Issue 500423003: Enhance GN diagnostic tools (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: use patterns for gn check Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/gn/pattern.cc ('k') | tools/gn/variables.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/gn/setup.cc
diff --git a/tools/gn/setup.cc b/tools/gn/setup.cc
index f6a20685c4099b958123819a09e2657eef6678fe..bdd0c17d3a59102c580273fac27fe77fea063d8b 100644
--- a/tools/gn/setup.cc
+++ b/tools/gn/setup.cc
@@ -18,8 +18,8 @@
#include "base/strings/string_util.h"
#include "base/strings/utf_string_conversions.h"
#include "build/build_config.h"
+#include "tools/gn/commands.h"
#include "tools/gn/filesystem_utils.h"
-#include "tools/gn/header_checker.h"
#include "tools/gn/input_file.h"
#include "tools/gn/parse_tree.h"
#include "tools/gn/parser.h"
@@ -188,19 +188,11 @@ bool CommonSetup::RunPostMessageLoop() {
}
if (check_public_headers_) {
- std::vector<const Target*> targets = builder_->GetAllResolvedTargets();
- scoped_refptr<HeaderChecker> header_checker(
- new HeaderChecker(&build_settings_, targets));
-
- std::vector<Err> header_errors;
- header_checker->Run(&header_errors);
- for (size_t i = 0; i < header_errors.size(); i++) {
- if (i > 0)
- OutputString("___________________\n", DECORATION_YELLOW);
- header_errors[i].PrintToStdout();
- }
- if (!header_errors.empty())
+ if (!commands::CheckPublicHeaders(&build_settings_,
+ builder_->GetAllResolvedTargets(),
+ std::vector<const Target*>())) {
return false;
+ }
}
// Write out tracing and timing if requested.
« no previous file with comments | « tools/gn/pattern.cc ('k') | tools/gn/variables.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698