]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-18107.stderr
Rollup merge of #105780 - GuillaumeGomez:read-more-links, r=notriddle
[rust.git] / src / test / ui / issues / issue-18107.stderr
1 error[E0746]: return type cannot have an unboxed trait object
2   --> $DIR/issue-18107.rs:4:5
3    |
4 LL |     dyn AbstractRenderer
5    |     ^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
6    |
7 help: use `impl AbstractRenderer` as the return type if all return paths have the same type but you want to expose only the trait in the signature
8    |
9 LL |     impl AbstractRenderer
10    |
11 help: use a boxed trait object if all return paths implement trait `AbstractRenderer`
12    |
13 LL |     Box<dyn AbstractRenderer>
14    |     ++++                    +
15
16 error: aborting due to previous error
17
18 For more information about this error, try `rustc --explain E0746`.