[PATCH] D92992: [clang-tidy] Add make_unique_for_overwrite/make_shared_for_overwrite check.

Eugene Zelenko via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Dec 9 21:48:31 PST 2020


Eugene.Zelenko added inline comments.


================
Comment at: clang-tools-extra/docs/ReleaseNotes.rst:143
 
+- New :doc:`modernize-make-shared-for-overwrite
+  <clang-tidy/checks/modernize-make-shared-for-overwrite>` check.
----------------
Please keep alphabetical order.


================
Comment at: clang-tools-extra/docs/ReleaseNotes.rst:146
+
+  Replaces default initialized objects in `new` expressions with a call to
+  `std::make_shared_for_overwrite` introduced in C++20.
----------------
Please use double back-ticks to highlight language constructs. Same below.


================
Comment at: clang-tools-extra/docs/clang-tidy/checks/modernize-make-shared-for-overwrite.rst:6
+
+This check finds the creation of ``std::shared_ptr`` objects by explicitly
+calling the constructor and a ``new`` expression where default initialization
----------------
Please make same as entry in Release Notes.


================
Comment at: clang-tools-extra/docs/clang-tidy/checks/modernize-make-unique-for-overwrite.rst:6
+
+This check finds the creation of ``std::unique_ptr`` objects by explicitly
+calling the constructor and a ``new`` expression where default initialization
----------------
Please make same as entry in Release Notes.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D92992/new/

https://reviews.llvm.org/D92992



More information about the cfe-commits mailing list