GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — src: do not redefine private for GenDebugSymbols by joyeecheung · Pull Request #18653 · nodejs/node

Conversation

@joyeecheung

@joyeecheung joyeecheung commented Feb 8, 2018

Copy link
Copy Markdown
Member

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.

Refs: #14901 (comment)

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines
Affected core subsystem(s)

src

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@joyeecheung
src: do not redefine private for GenDebugSymbols
cce09c3
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.
@nodejs-github-bot nodejs-github-bot added c++ Issues and PRs that require attention from people who are familiar with C++. lib / src Issues and PRs involving general changes in the lib/ or src/ directories. labels Feb 8, 2018
@joyeecheung

joyeecheung commented Feb 8, 2018

Copy link
Copy Markdown
Member Author

CI: https://ci.nodejs.org/job/node-test-pull-request/13045/

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

addaleax
addaleax approved these changes Feb 8, 2018
View reviewed changes
mmarchini
mmarchini approved these changes Feb 8, 2018
View reviewed changes

@mmarchini mmarchini left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Redefining private was a reasonable approach for the first version of GenDebugSymbols when it was created by a Python script, but for the current approach explicitly declaring those classes as friends of GenDebugSymbols makes more sense IMO.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread src/node_postmortem_metadata.cc Outdated
@@ -44,14 +44,6 @@
#include <utility>

@mmarchini mmarchini Feb 8, 2018

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can remove those includes as well since they are only here to avoid problems with private class inheritance

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@joyeecheung
squash! remove unnecessary std lib includes
b56fc10
@joyeecheung

joyeecheung commented Feb 8, 2018

Copy link
Copy Markdown
Member Author

@mmarchini Thanks for the suggestion, updated.

New CI: https://ci.nodejs.org/job/node-test-pull-request/13047/

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

bnoordhuis
bnoordhuis approved these changes Feb 8, 2018
View reviewed changes
Comment thread src/base_object.h Outdated

namespace node {

int GenDebugSymbols();

@bnoordhuis bnoordhuis Feb 8, 2018

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Correct me if I'm wrong but I don't think you have to forward-declare it, just the friend stanza inside the class is enough.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@joyeecheung
squash! remove unnecessary forward declaration
b37013c
@joyeecheung

joyeecheung commented Feb 8, 2018

Copy link
Copy Markdown
Member Author

@bnoordhuis Indeed, those forward declarations are not necessary. Thanks!

New CI: https://ci.nodejs.org/job/node-test-pull-request/13048/

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@BridgeAR BridgeAR added the author ready PRs with CI started, the required approvals, and no outstanding review comments. label Feb 9, 2018
cjihrig
cjihrig approved these changes Feb 9, 2018
View reviewed changes
jasnell
jasnell approved these changes Feb 9, 2018
View reviewed changes
@joyeecheung

joyeecheung commented Feb 14, 2018

Copy link
Copy Markdown
Member Author

CI before landing: https://ci.nodejs.org/job/node-test-pull-request/13167/

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@joyeecheung

joyeecheung commented Feb 14, 2018

Copy link
Copy Markdown
Member Author

There were some infra issues. New CI is green: https://ci.nodejs.org/job/node-test-commit/16238/

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@joyeecheung

joyeecheung commented Feb 14, 2018

Copy link
Copy Markdown
Member Author

Landed in 18d23aa, thanks!

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@joyeecheung joyeecheung closed this Feb 14, 2018
joyeecheung added a commit that referenced this pull request Feb 14, 2018
@joyeecheung
src: do not redefine private for GenDebugSymbols
18d23aa
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: #18653
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Ben Noordhuis <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: James M Snell <[email protected]>
@MylesBorins MylesBorins added the backport-requested-v9.x label Feb 21, 2018
@MylesBorins

MylesBorins commented Feb 21, 2018

Copy link
Copy Markdown
Contributor

Should this be backported to v9.x-staging? If yes please follow the guide and raise a backport PR, if not let me know or add the dont-land-on label.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@joyeecheung joyeecheung removed the author ready PRs with CI started, the required approvals, and no outstanding review comments. label Feb 21, 2018
@joyeecheung

joyeecheung commented Feb 21, 2018

Copy link
Copy Markdown
Member Author

This is a fix for #14901 so cannot land until that one lands.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@mmarchini mmarchini mentioned this pull request Feb 22, 2018
[v9.x backport] node internals' postmortem metadata (#14901, #18530, #18653, #18576) #18550
Closed
4 tasks done
@mmarchini

mmarchini commented Feb 22, 2018

Copy link
Copy Markdown
Contributor

v9.x backport PR: #18550

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@addaleax addaleax added backported-to-v9.x and removed backport-requested-v9.x labels Feb 26, 2018
mmarchini pushed a commit to mmarchini/node that referenced this pull request Feb 26, 2018
@joyeecheung Matheus Marchini
src: do not redefine private for GenDebugSymbols
d26e658
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: nodejs#18653
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Ben Noordhuis <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: James M Snell <[email protected]>
addaleax pushed a commit that referenced this pull request Feb 26, 2018
@joyeecheung @addaleax
src: do not redefine private for GenDebugSymbols
b7d9389
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.

Backport-PR-URL: #18550
PR-URL: #18653
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Ben Noordhuis <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: James M Snell <[email protected]>
MylesBorins pushed a commit that referenced this pull request Feb 26, 2018
@joyeecheung @MylesBorins
src: do not redefine private for GenDebugSymbols
189e566
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.

Backport-PR-URL: #18550
PR-URL: #18653
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Ben Noordhuis <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: James M Snell <[email protected]>
@addaleax addaleax mentioned this pull request Feb 27, 2018
v9.7.0 proposal #19040
Closed
mmarchini pushed a commit to mmarchini/node that referenced this pull request Mar 6, 2018
@joyeecheung Matheus Marchini
src: do not redefine private for GenDebugSymbols
0fce524
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: nodejs#18653
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Ben Noordhuis <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: James M Snell <[email protected]>
@mmarchini mmarchini mentioned this pull request Mar 6, 2018
[v8.x backport] node internals' postmortem metadata (#14901, #18530, #18653) #19176
Closed
4 tasks done
mmarchini pushed a commit to mmarchini/node that referenced this pull request Mar 13, 2018
@joyeecheung Matheus Marchini
src: do not redefine private for GenDebugSymbols
c7040a1
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: nodejs#18653
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Ben Noordhuis <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: James M Snell <[email protected]>
@mmarchini mmarchini mentioned this pull request Mar 13, 2018
[v6.x backport] node internals' postmortem metadata (#14901, #18530, #18653) #19323
Closed
4 tasks done
MayaLekova pushed a commit to MayaLekova/node that referenced this pull request May 8, 2018
@joyeecheung @MayaLekova
src: do not redefine private for GenDebugSymbols
a77500a
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: nodejs#18653
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Ben Noordhuis <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: James M Snell <[email protected]>
@MylesBorins MylesBorins added the backported-to-v8.x label May 22, 2018
MylesBorins pushed a commit that referenced this pull request May 22, 2018
@joyeecheung @MylesBorins
src: do not redefine private for GenDebugSymbols
5ac4bac
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: #18653
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Ben Noordhuis <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: James M Snell <[email protected]>
MylesBorins pushed a commit that referenced this pull request May 22, 2018
@joyeecheung @MylesBorins
src: do not redefine private for GenDebugSymbols
591812f
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.

Backport-PR-URL: #19176
PR-URL: #18653
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Ben Noordhuis <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: James M Snell <[email protected]>
MylesBorins pushed a commit that referenced this pull request Jun 14, 2018
@joyeecheung @MylesBorins
src: do not redefine private for GenDebugSymbols
2e7cd19
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.

Backport-PR-URL: #19176
PR-URL: #18653
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Ben Noordhuis <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: James M Snell <[email protected]>
@MylesBorins MylesBorins mentioned this pull request Jul 9, 2018
v8.12.0 proposal #21593
Merged
rvagg pushed a commit that referenced this pull request Aug 16, 2018
@joyeecheung @rvagg
src: do not redefine private for GenDebugSymbols
75b456d
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.

Backport-PR-URL: #19176
PR-URL: #18653
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Ben Noordhuis <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: James M Snell <[email protected]>
This was referenced Mar 7, 2020
[Snyk] Security upgrade gatsby from 2.13.73 to 2.16.2 meghasfdc/node#4
Open
[Snyk] Security upgrade gatsby from 2.13.73 to 2.16.2 kissofire/node#3
Open
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@bnoordhuis bnoordhuis bnoordhuis approved these changes
@jasnell jasnell jasnell approved these changes
@addaleax addaleax addaleax approved these changes
@cjihrig cjihrig cjihrig approved these changes
+1 more reviewer
@mmarchini mmarchini mmarchini approved these changes
Reviewers whose approvals may not affect merge requirements

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

c++ Issues and PRs that require attention from people who are familiar with C++. lib / src Issues and PRs involving general changes in the lib/ or src/ directories.

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

9 participants

@joyeecheung @MylesBorins @mmarchini @bnoordhuis @jasnell @addaleax @cjihrig @BridgeAR @nodejs-github-bot
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.