Zero as a default value is such an underrated technique. Vulkan is the perfect example of how not to do this. Oh, you forgot to set literally every single field in a struct? Congrats, your screen is black now.
Vulkan requires zero initialization of structures? Anyone writing developer education materials around such interfaces needs to point out that it is valid 1970s-era K&R C to write:
No, I meant how zero is not typically a reasonable default value, so if you do zero out structures, you'll probably end up with something you didn't want
Zero as a default value is such an underrated technique. Vulkan is the perfect example of how not to do this. Oh, you forgot to set literally every single field in a struct? Congrats, your screen is black now.
Vulkan requires zero initialization of structures? Anyone writing developer education materials around such interfaces needs to point out that it is valid 1970s-era K&R C to write:
CUDA_MEMCPY3D cp = {0};
No, I meant how zero is not typically a reasonable default value, so if you do zero out structures, you'll probably end up with something you didn't want