Specific error for unsized dyn Trait return type

Suggest `impl Trait` when possible, and `Box<dyn Trait>` otherwise.
This commit is contained in:
Esteban Küber 2020-01-13 13:13:12 -08:00
parent 9fe05e9456
commit 6fd564112f
7 changed files with 512 additions and 2 deletions

View file

@ -608,4 +608,5 @@ E0745: include_str!("./error_codes/E0745.md"),
E0726, // non-explicit (not `'_`) elided lifetime in unsupported position
E0727, // `async` generators are not yet supported
E0739, // invalid track_caller application/syntax
E0746, // `dyn Trait` return type
}