GeometryBuilder::build_* methods not consuming the builder #253
Replies: 1 comment
-
The main reason I made them non-consuming is so you can I am interested to see if other people think the naming is confusing though! The current names came about because I originally just had one |
Beta Was this translation helpful? Give feedback.
-
I ran into an oddity just now where I was using 2 geometrybuilders, and I turned them into a mesh with
build_mesh
:I noticed that this is valid code. Based on the method name
build_mesh
I assumed that the builder would be consumed, which would've prevented the small bug I have above.According to the Rust naming guidelines the common keyword for consuming a struct are
.as_
,.to_
and.into_
..build_
is not one of those keywords.My question is if it makes sense for other people that
.build_*
would consume the builder, or if they think it's fine as-is.(for a backwards compatible change we could introduce a
.finish_mesh
and a.finish_buffer
method instead)Beta Was this translation helpful? Give feedback.
All reactions