mirror of
https://github.com/AxioDL/metaforce.git
synced 2025-12-09 11:07:44 +00:00
Numerous uninitialized memory fixes
This commit is contained in:
@@ -477,8 +477,20 @@ public:
|
||||
const_reverse_iterator crbegin() const noexcept { return rbegin(); }
|
||||
const_reverse_iterator crend() const noexcept { return rend(); }
|
||||
|
||||
T& operator[](size_t idx) { return _value(idx); }
|
||||
const T& operator[](size_t idx) const { return _value(idx); }
|
||||
T& operator[](size_t idx) {
|
||||
#ifndef NDEBUG
|
||||
if (idx >= x0_size)
|
||||
Log.report(logvisor::Fatal, "out of bounds access on reserved_vector.");
|
||||
#endif
|
||||
return _value(idx);
|
||||
}
|
||||
const T& operator[](size_t idx) const {
|
||||
#ifndef NDEBUG
|
||||
if (idx >= x0_size)
|
||||
Log.report(logvisor::Fatal, "out of bounds access on reserved_vector.");
|
||||
#endif
|
||||
return _value(idx);
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user