summaryrefslogtreecommitdiff
path: root/src/req_wrap.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/req_wrap.h')
-rw-r--r--src/req_wrap.h10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/req_wrap.h b/src/req_wrap.h
index 83baf9d2a3..05bc558570 100644
--- a/src/req_wrap.h
+++ b/src/req_wrap.h
@@ -27,9 +27,13 @@ class ReqWrap : public AsyncWrap {
protected:
// req_wrap_queue_ needs to be at a fixed offset from the start of the class
// because it is used by ContainerOf to calculate the address of the embedding
- // ReqWrap. ContainerOf compiles down to simple, fixed pointer arithmetic.
- // sizeof(req_) depends on the type of T, so req_wrap_queue_ would
- // no longer be at a fixed offset if it came after req_.
+ // ReqWrap. ContainerOf compiles down to simple, fixed pointer arithmetic. It
+ // is also used by src/node_postmortem_metadata.cc to calculate offsets and
+ // generate debug symbols for ReqWrap, which assumes that the position of
+ // members in memory are predictable. sizeof(req_) depends on the type of T,
+ // so req_wrap_queue_ would no longer be at a fixed offset if it came after
+ // req_. For more information please refer to
+ // `doc/guides/node-postmortem-support.md`
T req_;
};