1
Fork 0

lint: port pass-by-value diagnostics

Signed-off-by: David Wood <david.wood@huawei.com>
This commit is contained in:
David Wood 2022-06-27 16:57:40 +01:00
parent 855f23773b
commit 37588d6d4e
2 changed files with 7 additions and 3 deletions

View file

@ -128,3 +128,6 @@ lint-non-upper_case-global = {$sort} `{$name}` should have an upper case name
lint-noop-method-call = call to `.{$method}()` on a reference in this situation does nothing
.label = unnecessary method call
.note = the type `{$receiver_ty}` which `{$method}` is being called on is the same as the type returned from `{$method}`, so the method call does not do anything and can be removed
lint-pass-by-value = passing `{$ty}` by reference
.suggestion = try passing by value