rust-unofficial / patterns

A catalogue of Rust design patterns, anti-patterns and idioms
https://rust-unofficial.github.io/patterns/
Mozilla Public License 2.0
7.85k stars 354 forks source link

Update coercion-arguments.md #285

Closed alsotang closed 2 years ago

alsotang commented 2 years ago

wrong order

pickfire commented 2 years ago

I don't see why it is wrong. Previous is &String vs &str and then &Vec<T> vs &[T].

alsotang commented 2 years ago

image

Or maybe the Box one is not align?

MarcoIeni commented 2 years ago

I think it's Box to be not aligned, yes

alsotang commented 2 years ago

closed by https://github.com/rust-unofficial/patterns/pull/286/files