summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJonathan Bradley <jcb@pikum.xyz>2023-12-21 15:55:56 -0500
committerJonathan Bradley <jcb@pikum.xyz>2023-12-23 11:41:03 -0500
commitce30c733ddc187472c6040415c3442d10748c133 (patch)
treebd737996d70d0500804acdc791a12ba08c46571e /src
parent04f5688a37030aa8598ded416f05d0cc979c37d6 (diff)
soft reset array
Diffstat (limited to 'src')
-rw-r--r--src/array.hpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/array.hpp b/src/array.hpp
index db8c564..46eab2e 100644
--- a/src/array.hpp
+++ b/src/array.hpp
@@ -26,6 +26,10 @@ void PkeArray_HardReset(PkeArray_Base *arrIn) {
arr->data = CAFE_BABE(D);
}
+inline void PkeArray_SoftReset(PkeArray_Base *arrIn) {
+ arrIn->next = 0;
+}
+
template<typename D>
inline void PkeArray_Add(PkeArray_Base *arrIn, const D &val, MemBucket *bkt = nullptr) {
auto *arr = static_cast<PkeArray<D> *>(arrIn);