You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In my code, I set the non-pointer members of Vulkan structs using the struct notation directly, before setting the pointers at the end. Because of the safety advantages, I would like to set pointers using the builder, but I find it unnecessary to set everything else using the builder as well. So I propose adding a method into_builder alongside the existing builder method, that unlike the latter takes self by value and uses it as a basis for creating the new builder. Using this, I could create a struct by directly setting members, convert it into a builder, and use that to set the pointer members. If you think it's appropriate, the into_builder method could set any pointer members to null explicitly so that the lifetimes are correct.
The text was updated successfully, but these errors were encountered:
The builders are now gone and the builder helper functions are now implemented directly on the Vulkan structs since #602, so this should work OOTB now 🎉
In my code, I set the non-pointer members of Vulkan structs using the struct notation directly, before setting the pointers at the end. Because of the safety advantages, I would like to set pointers using the builder, but I find it unnecessary to set everything else using the builder as well. So I propose adding a method
into_builder
alongside the existingbuilder
method, that unlike the latter takesself
by value and uses it as a basis for creating the new builder. Using this, I could create a struct by directly setting members, convert it into a builder, and use that to set the pointer members. If you think it's appropriate, theinto_builder
method could set any pointer members to null explicitly so that the lifetimes are correct.The text was updated successfully, but these errors were encountered: