-
Notifications
You must be signed in to change notification settings - Fork 25.7k
Make operation call accept Stack& instead of Stack* #63414
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Summary: Misuse of raw pointer in here where stack is never nullable. Test Plan: compiles. Reviewers: Subscribers: Tasks: Tags: [ghstack-poisoned]
🔗 Helpful links
💊 CI failures summary and remediationsAs of commit 7147a02 (more details on the Dr. CI page): 💚 💚 Looks good so far! There are no failures yet. 💚 💚 This comment was automatically generated by Dr. CI (expand for details).Follow this link to opt-out of these comments for your Pull Requests.Please report bugs/suggestions to the (internal) Dr. CI Users group. |
|
@zhxchen17 has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator. |
Summary: Misuse of raw pointer in here where stack is never nullable. Test Plan: compiles. Reviewers: Subscribers: Tasks: Tags: Differential Revision: [D30375410](https://our.internmc.facebook.com/intern/diff/D30375410) [ghstack-poisoned]
|
@zhxchen17 has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator. |
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.
Nice! Straightforward, positive change. I don't know why this was implemented with Stack* in the first place.
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.
Requesting changes as per internal discussion
Summary: Misuse of raw pointer in here where stack is never nullable. Test Plan: compiles. Reviewers: Subscribers: Tasks: Tags: Differential Revision: [D30375410](https://our.internmc.facebook.com/intern/diff/D30375410) [ghstack-poisoned]
|
@zhxchen17 has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator. |
|
|
||
| class Operation { | ||
| public: | ||
| template <typename F, |
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.
Update: Made this diff API compatible with registration.
Instead of switching over to Stack&, we can just add another constructor for Operation, such that it can take both Stack* and Stack& callback. For Stack* constructor we can make it explicit that it's deprecated, which shouldn't be a hard break for users.
Note that we wrap another level of lambda for Stack* callback to make the implementation uniform, which may have performance overhead but we can take it as a forcing factor for users to switch to Stack& callback. (or it can be inlined, I don't know).
Summary: Misuse of raw pointer in here where stack is never nullable. Test Plan: compiles. Reviewers: Subscribers: Tasks: Tags: Differential Revision: [D30375410](https://our.internmc.facebook.com/intern/diff/D30375410) [ghstack-poisoned]
|
@zhxchen17 has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator. |
Summary: Misuse of raw pointer in here where stack is never nullable. Test Plan: compiles. Reviewers: Subscribers: Tasks: Tags: Differential Revision: [D30375410](https://our.internmc.facebook.com/intern/diff/D30375410) [ghstack-poisoned]
|
@zhxchen17 has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator. |
Summary: Misuse of raw pointer in here where stack is never nullable. Test Plan: compiles. Reviewers: Subscribers: Tasks: Tags: Differential Revision: [D30375410](https://our.internmc.facebook.com/intern/diff/D30375410) [ghstack-poisoned]
|
@zhxchen17 has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator. |
Summary: Misuse of raw pointer in here where stack is never nullable. Test Plan: compiles. Reviewers: Subscribers: Tasks: Tags: Differential Revision: [D30375410](https://our.internmc.facebook.com/intern/diff/D30375410) [ghstack-poisoned]
|
@zhxchen17 has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator. |
Summary: Misuse of raw pointer in here where stack is never nullable. Test Plan: compiles. Reviewers: Subscribers: Tasks: Tags: Differential Revision: [D30375410](https://our.internmc.facebook.com/intern/diff/D30375410) [ghstack-poisoned]
Pull Request resolved: #63414 Misuse of raw pointer in here where stack is never nullable. Differential Revision: [D30375410](https://our.internmc.facebook.com/intern/diff/D30375410/) ghstack-source-id: 136834416
Summary: Misuse of raw pointer in here where stack is never nullable. Test Plan: compiles. Reviewers: Subscribers: Tasks: Tags: Differential Revision: [D30375410](https://our.internmc.facebook.com/intern/diff/D30375410) [ghstack-poisoned]
Summary: Misuse of raw pointer in here where stack is never nullable. Test Plan: compiles. Reviewers: Subscribers: Tasks: Tags: Differential Revision: [D30375410](https://our.internmc.facebook.com/intern/diff/D30375410) [ghstack-poisoned]
Summary: Misuse of raw pointer in here where stack is never nullable. Test Plan: compiles. Reviewers: Subscribers: Tasks: Tags: Differential Revision: [D30375410](https://our.internmc.facebook.com/intern/diff/D30375410) [ghstack-poisoned]
Pull Request resolved: #63414 Misuse of raw pointer in here where stack is never nullable. ghstack-source-id: 136938318 Differential Revision: [D30375410](https://our.internmc.facebook.com/intern/diff/D30375410/)
Summary: Pull Request resolved: pytorch/pytorch#63414 Misuse of raw pointer in here where stack is never nullable. ghstack-source-id: 136938318 Reviewed By: ejguan Differential Revision: D30375410 fbshipit-source-id: 9d65b620bb76d90d886c800f54308520095d58ee
|
This pull request has been merged in ac99d63. |
…#63414) Summary: Pull Request resolved: pytorch/pytorch#63414 Misuse of raw pointer in here where stack is never nullable. ghstack-source-id: 136938318 Reviewed By: ejguan Differential Revision: D30375410 fbshipit-source-id: 9d65b620bb76d90d886c800f54308520095d58ee
…#63414) (#4380) Summary: Pull Request resolved: pytorch/pytorch#63414 Misuse of raw pointer in here where stack is never nullable. ghstack-source-id: 136938318 Reviewed By: ejguan Differential Revision: D30375410 fbshipit-source-id: 9d65b620bb76d90d886c800f54308520095d58ee Co-authored-by: Zhengxu Chen <zhxchen17@fb.com>
Summary: Pull Request resolved: pytorch/pytorch#63414 Misuse of raw pointer in here where stack is never nullable. ghstack-source-id: 136938318 Test Plan: compiles. Imported from OSS Reviewed By: ejguan Differential Revision: D30375410 fbshipit-source-id: 9d65b620bb76d90d886c800f54308520095d58ee
Summary: Pull Request resolved: pytorch/pytorch#63414 Misuse of raw pointer in here where stack is never nullable. ghstack-source-id: 136938318 Test Plan: compiles. Imported from OSS Reviewed By: ejguan Differential Revision: D30375410 fbshipit-source-id: 9d65b620bb76d90d886c800f54308520095d58ee
Stack from ghstack:
Summary:
Misuse of raw pointer in here where stack is never nullable.
Test Plan:
compiles.
Reviewers:
Subscribers:
Tasks:
Tags:
Differential Revision: D30375410