From 18d23aa36e7f91bbc8dc6eb5972d2663a3a3df35 Mon Sep 17 00:00:00 2001 From: Joyee Cheung Date: Fri, 9 Feb 2018 03:34:50 +0800 Subject: src: do not redefine private for GenDebugSymbols Redefining private breaks any private inheritance in the included files. We can simply declare GenDebugSymbols() as friends in related classes to gain the access that we need. PR-URL: https://github.com/nodejs/node/pull/18653 Reviewed-By: Anna Henningsen Reviewed-By: Ben Noordhuis Reviewed-By: Colin Ihrig Reviewed-By: James M Snell --- src/handle_wrap.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/handle_wrap.h') diff --git a/src/handle_wrap.h b/src/handle_wrap.h index 1cfe3e2ebb..19fd36891a 100644 --- a/src/handle_wrap.h +++ b/src/handle_wrap.h @@ -81,11 +81,13 @@ class HandleWrap : public AsyncWrap { friend class Environment; friend void GetActiveHandles(const v8::FunctionCallbackInfo&); static void OnClose(uv_handle_t* handle); + // handle_wrap_queue_ needs to be at a fixed offset from the start of the // class because it is used by src/node_postmortem_metadata.cc to calculate // offsets and generate debug symbols for HandleWrap, which assumes that the // position of members in memory are predictable. For more information please // refer to `doc/guides/node-postmortem-support.md` + friend int GenDebugSymbols(); ListNode handle_wrap_queue_; enum { kInitialized, kClosing, kClosingWithCallback, kClosed } state_; uv_handle_t* const handle_; -- cgit v1.2.3