2022-09-07 19:09:33 +00:00
|
|
|
error: `data` option not allowed here
|
2024-07-19 12:05:39 +00:00
|
|
|
--> tests/compile-fail/tracked_fn_incompatibles.rs:8:18
|
|
|
|
|
|
|
|
|
8 | #[salsa::tracked(data = Data)]
|
|
|
|
| ^^^^
|
2022-09-07 19:09:33 +00:00
|
|
|
|
|
|
|
error: `db` option not allowed here
|
2024-07-19 12:05:39 +00:00
|
|
|
--> tests/compile-fail/tracked_fn_incompatibles.rs:13:18
|
2022-09-07 19:09:33 +00:00
|
|
|
|
|
2024-07-19 12:05:39 +00:00
|
|
|
13 | #[salsa::tracked(db = Db)]
|
|
|
|
| ^^
|
2022-09-07 19:09:33 +00:00
|
|
|
|
|
|
|
error: `constructor` option not allowed here
|
2024-07-19 12:05:39 +00:00
|
|
|
--> tests/compile-fail/tracked_fn_incompatibles.rs:18:18
|
2022-09-07 19:09:33 +00:00
|
|
|
|
|
2024-07-19 12:05:39 +00:00
|
|
|
18 | #[salsa::tracked(constructor = TrackedFn3)]
|
|
|
|
| ^^^^^^^^^^^
|
2022-09-07 19:09:33 +00:00
|
|
|
|
|
|
|
error: #[salsa::tracked] must also be applied to the impl block for tracked methods
|
2024-07-19 12:05:39 +00:00
|
|
|
--> tests/compile-fail/tracked_fn_incompatibles.rs:27:55
|
2022-09-07 19:09:33 +00:00
|
|
|
|
|
2024-07-19 12:05:39 +00:00
|
|
|
27 | fn tracked_fn_with_receiver_not_applied_to_impl_block(&self, db: &dyn Db) -> u32 {}
|
|
|
|
| ^^^^^
|
2022-09-07 19:09:33 +00:00
|
|
|
|
2024-07-19 12:05:39 +00:00
|
|
|
error: only functions with a single salsa struct as their input can be specified
|
|
|
|
--> tests/compile-fail/tracked_fn_incompatibles.rs:29:18
|
2022-09-07 21:19:05 +00:00
|
|
|
|
|
2024-07-19 12:05:39 +00:00
|
|
|
29 | #[salsa::tracked(specify)]
|
|
|
|
| ^^^^^^^
|
2024-05-13 09:13:34 +00:00
|
|
|
|
|
|
|
error[E0308]: mismatched types
|
2024-07-19 12:05:39 +00:00
|
|
|
--> tests/compile-fail/tracked_fn_incompatibles.rs:24:46
|
2024-05-13 09:13:34 +00:00
|
|
|
|
|
2024-07-19 12:05:39 +00:00
|
|
|
23 | #[salsa::tracked]
|
|
|
|
| ----------------- implicitly returns `()` as its body has no tail or `return` expression
|
|
|
|
24 | fn tracked_fn_with_one_input(db: &dyn Db) -> u32 {}
|
|
|
|
| ^^^ expected `u32`, found `()`
|