summaryrefslogtreecommitdiff
path: root/src/lib/spl.h
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2022-12-01 11:52:54 +0100
committerCarl Hetherington <cth@carlh.net>2022-12-01 11:52:54 +0100
commit704e1112538d809fd55bd7f25385eaa5d064966c (patch)
tree71563e3d9cbd182af63fac0f96faba4f73e20ec7 /src/lib/spl.h
parentbf471e4e6d2502bb3b4e2eb4b1309d87e1003070 (diff)
Remove unnecessary non-const operator[].
Diffstat (limited to 'src/lib/spl.h')
-rw-r--r--src/lib/spl.h4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/lib/spl.h b/src/lib/spl.h
index d7c746d1e..b002a0882 100644
--- a/src/lib/spl.h
+++ b/src/lib/spl.h
@@ -59,12 +59,10 @@ public:
return _spl;
}
- SPLEntry & operator[] (std::size_t index) {
+ SPLEntry const & operator[] (std::size_t index) const {
return _spl[index];
}
- SPLEntry const & operator[] (std::size_t index) const {
- return _spl[index];
void swap(size_t a, size_t b) {
std::iter_swap(_spl.begin() + a, _spl.begin() + b);
}