rust/tests/ui-fulldeps/internal-lints/rustc_pass_by_value.stderr

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

129 lines
4.7 KiB
Plaintext
Raw Normal View History

2019-04-24 16:24:00 -05:00
error: passing `Ty<'_>` by reference
--> $DIR/rustc_pass_by_value.rs:14:13
2019-04-24 16:24:00 -05:00
|
LL | ty_ref: &Ty<'_>,
| ^^^^^^^ help: try passing by value: `Ty<'_>`
|
2020-01-22 17:57:38 -06:00
note: the lint level is defined here
--> $DIR/rustc_pass_by_value.rs:5:9
2019-04-24 16:24:00 -05:00
|
LL | #![deny(rustc::pass_by_value)]
| ^^^^^^^^^^^^^^^^^^^^
2019-04-24 16:24:00 -05:00
2019-06-13 16:48:52 -05:00
error: passing `TyCtxt<'_>` by reference
--> $DIR/rustc_pass_by_value.rs:16:18
2019-04-24 16:24:00 -05:00
|
2019-06-13 16:48:52 -05:00
LL | ty_ctxt_ref: &TyCtxt<'_>,
| ^^^^^^^^^^^ help: try passing by value: `TyCtxt<'_>`
2019-04-24 16:24:00 -05:00
error: passing `Ty<'_>` by reference
--> $DIR/rustc_pass_by_value.rs:20:28
2019-04-24 16:24:00 -05:00
|
2019-06-13 16:48:52 -05:00
LL | fn ty_multi_ref(ty_multi: &&Ty<'_>, ty_ctxt_multi: &&&&TyCtxt<'_>) {}
2019-04-24 16:24:00 -05:00
| ^^^^^^^ help: try passing by value: `Ty<'_>`
2019-06-13 16:48:52 -05:00
error: passing `TyCtxt<'_>` by reference
--> $DIR/rustc_pass_by_value.rs:20:55
2019-04-24 16:24:00 -05:00
|
2019-06-13 16:48:52 -05:00
LL | fn ty_multi_ref(ty_multi: &&Ty<'_>, ty_ctxt_multi: &&&&TyCtxt<'_>) {}
| ^^^^^^^^^^^ help: try passing by value: `TyCtxt<'_>`
2019-04-24 16:24:00 -05:00
error: passing `Ty<'_>` by reference
--> $DIR/rustc_pass_by_value.rs:27:17
2019-04-24 16:24:00 -05:00
|
LL | ty_ref: &Ty<'_>,
| ^^^^^^^ help: try passing by value: `Ty<'_>`
2019-06-13 16:48:52 -05:00
error: passing `TyCtxt<'_>` by reference
--> $DIR/rustc_pass_by_value.rs:29:22
2019-04-24 16:24:00 -05:00
|
2019-06-13 16:48:52 -05:00
LL | ty_ctxt_ref: &TyCtxt<'_>,
| ^^^^^^^^^^^ help: try passing by value: `TyCtxt<'_>`
2019-04-24 16:24:00 -05:00
error: passing `Ty<'_>` by reference
--> $DIR/rustc_pass_by_value.rs:32:41
2019-04-24 16:24:00 -05:00
|
2019-06-13 16:48:52 -05:00
LL | fn ty_multi_ref_in_trait(ty_multi: &&Ty<'_>, ty_ctxt_multi: &&&&TyCtxt<'_>);
2019-04-24 16:24:00 -05:00
| ^^^^^^^ help: try passing by value: `Ty<'_>`
2019-06-13 16:48:52 -05:00
error: passing `TyCtxt<'_>` by reference
--> $DIR/rustc_pass_by_value.rs:32:68
2019-04-24 16:24:00 -05:00
|
2019-06-13 16:48:52 -05:00
LL | fn ty_multi_ref_in_trait(ty_multi: &&Ty<'_>, ty_ctxt_multi: &&&&TyCtxt<'_>);
| ^^^^^^^^^^^ help: try passing by value: `TyCtxt<'_>`
2019-04-24 16:24:00 -05:00
error: passing `Ty<'_>` by reference
--> $DIR/rustc_pass_by_value.rs:54:17
2019-04-24 16:24:00 -05:00
|
LL | ty_ref: &Ty<'_>,
| ^^^^^^^ help: try passing by value: `Ty<'_>`
2019-06-13 16:48:52 -05:00
error: passing `TyCtxt<'_>` by reference
--> $DIR/rustc_pass_by_value.rs:56:22
2019-04-24 16:24:00 -05:00
|
2019-06-13 16:48:52 -05:00
LL | ty_ctxt_ref: &TyCtxt<'_>,
| ^^^^^^^^^^^ help: try passing by value: `TyCtxt<'_>`
2019-04-24 16:24:00 -05:00
error: passing `Ty<'_>` by reference
--> $DIR/rustc_pass_by_value.rs:60:38
2019-04-24 16:24:00 -05:00
|
2019-06-13 16:48:52 -05:00
LL | fn ty_multi_ref_assoc(ty_multi: &&Ty<'_>, ty_ctxt_multi: &&&&TyCtxt<'_>) {}
2019-04-24 16:24:00 -05:00
| ^^^^^^^ help: try passing by value: `Ty<'_>`
2019-06-13 16:48:52 -05:00
error: passing `TyCtxt<'_>` by reference
--> $DIR/rustc_pass_by_value.rs:60:65
2019-04-24 16:24:00 -05:00
|
2019-06-13 16:48:52 -05:00
LL | fn ty_multi_ref_assoc(ty_multi: &&Ty<'_>, ty_ctxt_multi: &&&&TyCtxt<'_>) {}
| ^^^^^^^^^^^ help: try passing by value: `TyCtxt<'_>`
2019-04-24 16:24:00 -05:00
error: passing `CustomEnum` by reference
--> $DIR/rustc_pass_by_value.rs:74:20
|
LL | reference: &CustomEnum,
| ^^^^^^^^^^^ help: try passing by value: `CustomEnum`
error: passing `CustomStruct` by reference
--> $DIR/rustc_pass_by_value.rs:85:24
|
LL | type CustomAlias<'a> = &'a CustomStruct;
| ^^^^^^^^^^^^^^^^ help: try passing by value: `CustomStruct`
error: passing `CustomStruct` by reference
--> $DIR/rustc_pass_by_value.rs:90:20
|
LL | reference: &CustomStruct,
| ^^^^^^^^^^^^^ help: try passing by value: `CustomStruct`
2022-06-04 15:50:19 -05:00
error: passing `CustomAlias<'_>` by reference
--> $DIR/rustc_pass_by_value.rs:96:20
|
LL | reference: &CustomAlias,
2022-06-04 15:50:19 -05:00
| ^^^^^^^^^^^^ help: try passing by value: `CustomAlias<'_>`
error: passing `WithParameters<T, 1>` by reference
--> $DIR/rustc_pass_by_value.rs:110:20
|
LL | reference: &'a WithParameters<T, 1>,
| ^^^^^^^^^^^^^^^^^^^^^^^^ help: try passing by value: `WithParameters<T, 1>`
error: passing `WithParameters<T, 1, u32>` by reference
--> $DIR/rustc_pass_by_value.rs:111:27
|
LL | reference_with_m: &WithParameters<T, 1, u32>,
| ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try passing by value: `WithParameters<T, 1, u32>`
error: passing `WithParameters<T, 1>` by reference
--> $DIR/rustc_pass_by_value.rs:112:10
|
LL | ) -> &'a WithParameters<T, 1> {
| ^^^^^^^^^^^^^^^^^^^^^^^^ help: try passing by value: `WithParameters<T, 1>`
error: passing `WithParameters<_, 1>` by reference
--> $DIR/rustc_pass_by_value.rs:114:22
|
LL | reference as &WithParameters<_, 1>
| ^^^^^^^^^^^^^^^^^^^^^ help: try passing by value: `WithParameters<_, 1>`
error: aborting due to 20 previous errors
2019-04-24 16:24:00 -05:00