diff options
author | David Robillard <d@drobilla.net> | 2022-09-16 18:38:12 -0400 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2022-09-16 22:31:06 -0400 |
commit | af4d993a30cfde6df322fb58600b25faef424489 (patch) | |
tree | 706283d11880b666cf157fe9c7705d0c048748b4 /include | |
parent | b94a7282ecbde37c2b88fd8327a409cebe046b30 (diff) | |
download | chilbert-af4d993a30cfde6df322fb58600b25faef424489.tar.gz chilbert-af4d993a30cfde6df322fb58600b25faef424489.tar.bz2 chilbert-af4d993a30cfde6df322fb58600b25faef424489.zip |
Avoid repeating types in return statements
Diffstat (limited to 'include')
-rw-r--r-- | include/chilbert/SmallBitVec.hpp | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/include/chilbert/SmallBitVec.hpp b/include/chilbert/SmallBitVec.hpp index b1fe474..10668ac 100644 --- a/include/chilbert/SmallBitVec.hpp +++ b/include/chilbert/SmallBitVec.hpp @@ -330,16 +330,11 @@ public: return Mask{i}; } - iterator begin(const size_t i = 0) { return iterator(*this, i); } + iterator begin(const size_t i = 0) { return {*this, i}; } + iterator end() { return {*this, size()}; } - iterator end() { return iterator(*this, size()); } - - const_iterator begin(const size_t i = 0) const - { - return const_iterator(*this, i); - } - - const_iterator end() const { return const_iterator(*this, size()); } + const_iterator begin(const size_t i = 0) const { return {*this, i}; } + const_iterator end() const { return {*this, size()}; } private: static_assert(8 * sizeof(Rack) == bits_per_rack, ""); |