forked from facebook/infer
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[autofix] Add autofix for unnecessary copy on field init exp
Summary: ``` C(T f): f_(f) {} ================= C(T f): f_(std::move(f)) {} ``` This is one of the frequent unnecessary copy patterns that is straightforward to fix. This diff generates autofix when - the procedure is a constructor and - a field is initialized by a parameter. Reviewed By: ngorogiannis Differential Revision: D63505474 fbshipit-source-id: da0b162d4bc6e75ec9a6509707bee91a8f8868b9
- Loading branch information
1 parent
995d569
commit 0577b64
Showing
3 changed files
with
25 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters