aboutsummaryrefslogtreecommitdiff
path: root/common/array.h
diff options
context:
space:
mode:
Diffstat (limited to 'common/array.h')
-rw-r--r--common/array.h6
1 files changed, 2 insertions, 4 deletions
diff --git a/common/array.h b/common/array.h
index 9a40a392c4..6fde309ac4 100644
--- a/common/array.h
+++ b/common/array.h
@@ -78,11 +78,9 @@ public:
_size++;
}
- T& remove_at(int idx) {
- T& tmp;
-
+ T remove_at(int idx) {
assert(idx >= 0 && idx < _size);
- tmp = _data[idx];
+ T tmp = _data[idx];
for (int i = idx; i < _size - 1; i++)
_data[i] = _data[i+1];
_size--;