@@ -20,9 +20,8 @@ static bool hasCopyConstructor(CXXRecordDecl const &Node) {
2020 // unresolved
2121 for (CXXBaseSpecifier const &BS : Node.bases ()) {
2222 CXXRecordDecl const *BRD = BS.getType ()->getAsCXXRecordDecl ();
23- if (BRD != nullptr )
24- if (!hasCopyConstructor (*BRD))
25- return false ;
23+ if (BRD != nullptr && !hasCopyConstructor (*BRD))
24+ return false ;
2625 }
2726 }
2827 if (Node.hasSimpleCopyConstructor ())
@@ -39,9 +38,8 @@ static bool hasMoveConstructor(CXXRecordDecl const &Node) {
3938 // unresolved
4039 for (CXXBaseSpecifier const &BS : Node.bases ()) {
4140 CXXRecordDecl const *BRD = BS.getType ()->getAsCXXRecordDecl ();
42- if (BRD != nullptr )
43- if (!hasMoveConstructor (*BRD))
44- return false ;
41+ if (BRD != nullptr && !hasMoveConstructor (*BRD))
42+ return false ;
4543 }
4644 }
4745 if (Node.hasSimpleMoveConstructor ())
@@ -58,9 +56,8 @@ static bool hasCopyAssignment(CXXRecordDecl const &Node) {
5856 // unresolved
5957 for (CXXBaseSpecifier const &BS : Node.bases ()) {
6058 CXXRecordDecl const *BRD = BS.getType ()->getAsCXXRecordDecl ();
61- if (BRD != nullptr )
62- if (!hasCopyAssignment (*BRD))
63- return false ;
59+ if (BRD != nullptr && !hasCopyAssignment (*BRD))
60+ return false ;
6461 }
6562 }
6663 if (Node.hasSimpleCopyAssignment ())
@@ -77,9 +74,8 @@ static bool hasMoveAssignment(CXXRecordDecl const &Node) {
7774 // unresolved
7875 for (CXXBaseSpecifier const &BS : Node.bases ()) {
7976 CXXRecordDecl const *BRD = BS.getType ()->getAsCXXRecordDecl ();
80- if (BRD != nullptr )
81- if (!hasMoveAssignment (*BRD))
82- return false ;
77+ if (BRD != nullptr && !hasMoveAssignment (*BRD))
78+ return false ;
8379 }
8480 }
8581 if (Node.hasSimpleMoveAssignment ())
0 commit comments