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

Unified Diff: tools/gn/builder.h

Issue 2152413002: GN: don't write separate files for non-binary targets (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: typo Created 4 years, 5 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 | « no previous file | tools/gn/builder_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/gn/builder.h
diff --git a/tools/gn/builder.h b/tools/gn/builder.h
index 0c2fe70f70a57c4ad18bfc99602561880f99a470..d8209bc048f0729716804a7a66b3741e666287fe 100644
--- a/tools/gn/builder.h
+++ b/tools/gn/builder.h
@@ -8,7 +8,6 @@
#include "base/callback.h"
#include "base/containers/hash_tables.h"
#include "base/macros.h"
-#include "base/memory/ref_counted.h"
#include "tools/gn/builder_record.h"
#include "tools/gn/label.h"
#include "tools/gn/label_ptr.h"
@@ -19,11 +18,14 @@ class Err;
class Loader;
class ParseNode;
-class Builder : public base::RefCountedThreadSafe<Builder> {
+// The builder assembles the dependency tree. It is not threadsafe and runs on
+// the main thread only. See also BuilderRecord.
+class Builder {
public:
typedef base::Callback<void(const BuilderRecord*)> ResolvedCallback;
explicit Builder(Loader* loader);
+ ~Builder();
// The resolved callback is called whenever a target has been resolved. This
// will be executed only on the main thread.
@@ -53,10 +55,6 @@ class Builder : public base::RefCountedThreadSafe<Builder> {
bool CheckForBadItems(Err* err) const;
private:
- friend class base::RefCountedThreadSafe<Builder>;
-
- virtual ~Builder();
-
bool TargetDefined(BuilderRecord* record, Err* err);
bool ConfigDefined(BuilderRecord* record, Err* err);
bool ToolchainDefined(BuilderRecord* record, Err* err);
« no previous file with comments | « no previous file | tools/gn/builder_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698