#impl — Public Fediverse posts
Live and recent posts from across the Fediverse tagged #impl, aggregated by home.social.
-
I like the second way better too. I also like the idea of splitting the struct and its impls to its own file. Thanks everyone for your input.
-
In Rust if I have some structs that each implement a couple traits, what is the preferred way to order things?
trait … {}
trait …{}struct …{}
struct …{}
struct …{}impl…for …{}
impl…for …{}
impl…for …{}
impl…for …{}
impl…for …{}
impl…for …{}OR
trait …{}
trait …{}struct …{}
impl…for …{}
impl…for …{}struct …{}
impl…for …{}
impl…for …{}struct …{}
impl…for …{}
impl…for …{}OR, something else entirely?