This revision was automatically updated to reflect the committed changes.
hokein marked an inline comment as done.
Closed by commit rL362361: [clang-tidy] Fix make-unique check to work in C++17
mode. (authored by hokein, committed by ).
Herald added a project: LLVM.
Herald added a subscriber: llvm
hokein marked 2 inline comments as done.
hokein added inline comments.
Comment at: clang-tools-extra/clang-tidy/modernize/MakeSmartPtrCheck.cpp:311
+ }
+}
+if (CEArg->isStdInitListInitialization())
gribozavr wrote:
> So `Foo(Bar{1, 2})` i
gribozavr added inline comments.
Comment at: clang-tools-extra/clang-tidy/modernize/MakeSmartPtrCheck.cpp:306
+if (CEArg->isElidable()) {
+ if (const auto *TempExp = CEArg->getArg(0)) {
+if (const auto *UnwrappedCE =
Eugene.Zelenko wr
Eugene.Zelenko added inline comments.
Comment at: clang-tools-extra/clang-tidy/modernize/MakeSmartPtrCheck.cpp:306
+if (CEArg->isElidable()) {
+ if (const auto *TempExp = CEArg->getArg(0)) {
+if (const auto *UnwrappedCE =
gribozavr wr
gribozavr added inline comments.
Comment at: clang-tools-extra/clang-tidy/modernize/MakeSmartPtrCheck.cpp:306
+if (CEArg->isElidable()) {
+ if (const auto *TempExp = CEArg->getArg(0)) {
+if (const auto *UnwrappedCE =
Eugene.Zelenko wr
Eugene.Zelenko added inline comments.
Comment at: clang-tools-extra/clang-tidy/modernize/MakeSmartPtrCheck.cpp:306
+if (CEArg->isElidable()) {
+ if (const auto *TempExp = CEArg->getArg(0)) {
+if (const auto *UnwrappedCE =
gribozavr wr
gribozavr added inline comments.
Comment at: clang-tools-extra/clang-tidy/modernize/MakeSmartPtrCheck.cpp:306
+if (CEArg->isElidable()) {
+ if (const auto *TempExp = CEArg->getArg(0)) {
+if (const auto *UnwrappedCE =
Eugene.Zelenko wr
Eugene.Zelenko added inline comments.
Comment at: clang-tools-extra/clang-tidy/modernize/MakeSmartPtrCheck.cpp:306
+if (CEArg->isElidable()) {
+ if (const auto *TempExp = CEArg->getArg(0)) {
+if (const auto *UnwrappedCE =
gribozavr wr
gribozavr marked an inline comment as done.
gribozavr added inline comments.
Comment at: clang-tools-extra/clang-tidy/modernize/MakeSmartPtrCheck.cpp:306
+if (CEArg->isElidable()) {
+ if (const auto *TempExp = CEArg->getArg(0)) {
+if (const auto *Unwr
Eugene.Zelenko added inline comments.
Comment at: clang-tools-extra/clang-tidy/modernize/MakeSmartPtrCheck.cpp:306
+if (CEArg->isElidable()) {
+ if (const auto *TempExp = CEArg->getArg(0)) {
+if (const auto *UnwrappedCE =
Return type
gribozavr added inline comments.
Comment at: clang-tools-extra/clang-tidy/modernize/MakeSmartPtrCheck.cpp:311
+ }
+}
+if (CEArg->isStdInitListInitialization())
So `Foo(Bar{1, 2})` is not problematic, it is just that we can't tell it apart
hokein added inline comments.
Comment at: clang-tools-extra/clang-tidy/modernize/MakeSmartPtrCheck.cpp:304
+// e.g. Foo(Bar{1, 2}), the Bar init-list constructor is wrapped around
+// an elidable move constructor.
+if (CEArg->isElidable()) {
--
hokein updated this revision to Diff 202434.
hokein marked 6 inline comments as done.
hokein added a comment.
Address comments
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D62736/new/
https://reviews.llvm.org/D62736
Files:
clang-tools-extra/clan
gribozavr added inline comments.
Comment at: clang-tools-extra/clang-tidy/modernize/MakeSmartPtrCheck.cpp:302
+ if (const auto *CEArg = dyn_cast(Arg)) {
+// Strip the ediable move constructor, it is presented in C++11/14
mode.
+// e.g. Foo(Bar{1, 2}), the Ba
hokein created this revision.
hokein added a reviewer: gribozavr.
Herald added a subscriber: xazax.hun.
Herald added a project: clang.
Previously, we intended to omit the check fix to the case when constructor has
any braced-init-list argument. But the HasListInitializedArgument was not
correct to
15 matches
Mail list logo