Skip to content

Commit

Permalink
further fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
pca006132 committed Dec 25, 2024
1 parent 6bd7bfe commit 1045db7
Showing 1 changed file with 16 additions and 14 deletions.
30 changes: 16 additions & 14 deletions src/sdf/small_vector.h
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ class small_vector {
ptr_++;
return *this;

Check warning on line 259 in src/sdf/small_vector.h

View check run for this annotation

Codecov / codecov/patch

src/sdf/small_vector.h#L256-L259

Added lines #L256 - L259 were not covered by tests
}
self_type operator++(int) {
self_type operator++(int) const {
self_type i = *this;
ptr_++;
return i;
Expand All @@ -267,17 +267,19 @@ class small_vector {
ptr_--;
return *this;
}
self_type operator--(int) {
self_type operator--(int) const {
self_type i = *this;
ptr_--;
return i;
}
self_type operator+(size_type i) { return self_type(ptr_ + i); }
self_type operator-(size_type i) { return self_type(ptr_ - i); }
self_type operator+(size_type i) const { return self_type(ptr_ + i); }
self_type operator-(size_type i) const { return self_type(ptr_ - i); }
reference operator*() { return *ptr_; }
const value_type &operator*() const { return *ptr_; }
pointer operator->() { return ptr_; }
bool operator==(const self_type &rhs) { return ptr_ == rhs.ptr_; }
bool operator!=(const self_type &rhs) { return ptr_ != rhs.ptr_; }
const pointer operator->() const { return ptr_; }
bool operator==(const self_type &rhs) const { return ptr_ == rhs.ptr_; }
bool operator!=(const self_type &rhs) const { return ptr_ != rhs.ptr_; }

Check warning on line 282 in src/sdf/small_vector.h

View check run for this annotation

Codecov / codecov/patch

src/sdf/small_vector.h#L282

Added line #L282 was not covered by tests

private:
pointer ptr_;
Expand All @@ -296,7 +298,7 @@ class small_vector {
ptr_++;
return *this;
}
self_type operator++(int) {
self_type operator++(int) const {
self_type i = *this;
ptr_++;
return i;
Expand All @@ -305,17 +307,17 @@ class small_vector {
ptr_--;
return *this;

Check warning on line 308 in src/sdf/small_vector.h

View check run for this annotation

Codecov / codecov/patch

src/sdf/small_vector.h#L306-L308

Added lines #L306 - L308 were not covered by tests
}
self_type operator--(int) {
self_type operator--(int) const {
self_type i = *this;
ptr_--;
return i;
}
self_type operator+(size_type i) { return self_type(ptr_ + i); }
self_type operator-(size_type i) { return self_type(ptr_ - i); }
const value_type &operator*() { return *ptr_; }
const pointer operator->() { return ptr_; }
bool operator==(const self_type &rhs) { return ptr_ == rhs.ptr_; }
bool operator!=(const self_type &rhs) { return ptr_ != rhs.ptr_; }
self_type operator+(size_type i) const { return self_type(ptr_ + i); }
self_type operator-(size_type i) const { return self_type(ptr_ - i); }
reference operator*() const { return *ptr_; }

Check warning on line 317 in src/sdf/small_vector.h

View check run for this annotation

Codecov / codecov/patch

src/sdf/small_vector.h#L317

Added line #L317 was not covered by tests
pointer operator->() const { return ptr_; }
bool operator==(const self_type &rhs) const { return ptr_ == rhs.ptr_; }

Check warning on line 319 in src/sdf/small_vector.h

View check run for this annotation

Codecov / codecov/patch

src/sdf/small_vector.h#L319

Added line #L319 was not covered by tests
bool operator!=(const self_type &rhs) const { return ptr_ != rhs.ptr_; }

private:
pointer ptr_;
Expand Down

0 comments on commit 1045db7

Please sign in to comment.