Update rule S2807: typos (#4107)

This commit is contained in:
Arseniy Zaostrovnykh 2024-08-02 15:13:19 +02:00 committed by GitHub
parent a05bc3b14e
commit f3bd1c7b1c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -68,7 +68,8 @@ namespace lib {
}
----
The `operator/` will be considered as a candidate for any call `a / b` when either `a` or `b` is the namespace `lib`.
The `operator/` will be considered as a candidate for any call `a / b`
when either `a` or `b` are of a type declared in the namespace `lib`.
This not only makes compilation slower but also lists the function as a candidate in case of a compilation error,
making such a message less readable.
@ -138,7 +139,7 @@ public:
}
};
----
The call `i + 10` is well-formed and resolves to `i.operator(10)`,
The call `i + 10` is well-formed and resolves to `i.operator+(10)`,
which will convert `10` to an `Integer` object using the implicit converting constructor.
However, `10 + i` is ill-formed.