- A few Vulkan wrapper structs

- Framework for Vulkan context
 - Fixed a bug with dynarray where if `resize()` shrinks the array, destructors are not called.
 - Fixed grammar issues with the containers library and added property tables to existing data structures.
This commit is contained in:
2026-01-02 15:38:03 -05:00
parent c1be5385d3
commit 7c2f89b331
53 changed files with 825 additions and 415 deletions

View File

@@ -87,10 +87,10 @@ public:
/// \note If used with `::strlen`, the result should be incremented by 1 to include the null terminator
constexpr cstring(char* str, size_t n)
: _str(str)
, _size(n - 1)
, _size(n)
, _const(false) {
if constexpr(not is_constant_evaluated()) {
assert(_str[n - 1] == '\0', "Invalid NTBS.");
assert(_str[n] == '\0', "Invalid NTBS.");
}
}
@@ -114,10 +114,10 @@ public:
/// \note If used with `::strlen`, the result should be incremented by 1 to include the null terminator
constexpr cstring(const char* str, size_t n)
: _cstr(str)
, _size(n - 1)
, _size(n)
, _const(true) {
if constexpr(not is_constant_evaluated()) {
assert(_str[n - 1] == '\0', "Invalid NTBS.");
assert(_str[n] == '\0', "Invalid NTBS.");
}
}
@@ -195,7 +195,7 @@ public:
return _size + 1;
}
constexpr bool empty() const {
constexpr bool is_empty() const {
return _cstr == nullptr || _size == 0;
}