Skip to content

Commit e4bbfb9

Browse files
committed
CPP: Corrections.
1 parent 208f533 commit e4bbfb9

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

cpp/ql/src/semmle/code/cpp/Function.qll

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1059,7 +1059,7 @@ class CopyConstructor extends Constructor {
10591059
* ```
10601060
* class MyClass {
10611061
* public:
1062-
* MyClass(const MyClass &&from) {
1062+
* MyClass(MyClass &&from) {
10631063
* ...
10641064
* }
10651065
* };
@@ -1236,7 +1236,7 @@ class CopyAssignmentOperator extends Operator {
12361236
* ```
12371237
* class MyClass {
12381238
* public:
1239-
* MyClass &operator=(const MyClass &&other);
1239+
* MyClass &operator=(MyClass &&other);
12401240
* };
12411241
* ```
12421242
*
@@ -1267,8 +1267,9 @@ class MoveAssignmentOperator extends Operator {
12671267
* }
12681268
* ```
12691269
*
1270-
* This includes function declarations which are immediately preceded by
1271-
* `template <...>`, where the "..." part is not empty, but does not include:
1270+
* This comprises function declarations which are immediately preceded by
1271+
* `template <...>`, where the "..." part is not empty, and therefore it does
1272+
* not include:
12721273
*
12731274
* 1. Full specializations of template functions, as they have an empty
12741275
* template argument list.

cpp/ql/test/library-tests/functions/functions/functions.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,6 @@ class MyClass
3636
MyClass();
3737
MyClass(int from);
3838
MyClass(const MyClass &from);
39-
MyClass(const MyClass &&from);
39+
MyClass(MyClass &&from);
4040
operator int();
4141
};

0 commit comments

Comments
 (0)