Skip to content

Commit

Permalink
src: reduce unnecessary includes
Browse files Browse the repository at this point in the history
A forward declaration suffices and means that the tracing
agent header and its dependencies don’t need to be included
in nearly every Node.js file.

PR-URL: #21867
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Eugene Ostroukhov <eostroukhov@google.com>
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com>
  • Loading branch information
addaleax authored and targos committed Aug 1, 2018
1 parent ec9d529 commit cde0e5f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
1 change: 0 additions & 1 deletion src/env-inl.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@
#include "v8.h"
#include "node_perf_common.h"
#include "node_context_data.h"
#include "tracing/agent.h"
#include "node_worker.h"

#include <stddef.h>
Expand Down
5 changes: 4 additions & 1 deletion src/env.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@
#include "v8.h"
#include "node.h"
#include "node_http2_state.h"
#include "tracing/agent.h"

#include <list>
#include <stdint.h>
Expand All @@ -55,6 +54,10 @@ namespace performance {
class performance_state;
}

namespace tracing {
class Agent;
}

namespace worker {
class Worker;
}
Expand Down

0 comments on commit cde0e5f

Please sign in to comment.