% for enum in enums:
- const char *
- vk_${enum.name[2:]}_to_str(${enum.name} input)
- {
- switch(input) {
- % for v in enum.values:
- % if v in FOREIGN_ENUM_VALUES:
-
- #pragma GCC diagnostic push
- #pragma GCC diagnostic ignored "-Wswitch"
- % endif
- case ${v}:
- return "${v}";
- % if v in FOREIGN_ENUM_VALUES:
- #pragma GCC diagnostic pop
-
- % endif
- % endfor
- default:
- unreachable("Undefined enum value.");
- }
+ const char *
+ vk_${enum.name[2:]}_to_str(${enum.name} input)
+ {
+ switch(input) {
+ % for v in enum.values:
+ % if v in FOREIGN_ENUM_VALUES:
+
+ #pragma GCC diagnostic push
+ #pragma GCC diagnostic ignored "-Wswitch"
+ % endif
+ case ${v}:
+ return "${v}";
+ % if v in FOREIGN_ENUM_VALUES:
+ #pragma GCC diagnostic pop
+
+ % endif
+ % endfor
+ default:
+ unreachable("Undefined enum value.");
}
+ }
%endfor"""),
output_encoding='utf-8')
#include <vulkan/vk_android_native_buffer.h>
% for enum in enums:
- const char * vk_${enum.name[2:]}_to_str(${enum.name} input);
+ const char * vk_${enum.name[2:]}_to_str(${enum.name} input);
% endfor
#endif"""),