Open alteous opened 7 years ago
I think the reason why I didn't do this the first time was the impact to the user-facing API. It has a bit more overhead to consume the data, but that's initialization work not real-time work. Is there a way to do this without making the draw building API more verbose? I think I'd be OK with a small perf hit for some better developer ergonomics.
By taking
&mut self
instead ofmut self
, the user will be able to chain calls more ergonomically.This pattern is recommended by the Rust API guidelines.