Skip to content

Commit

Permalink
Remove unused GenericVector::contains_index, UnicityTable::contains_id
Browse files Browse the repository at this point in the history
Signed-off-by: Stefan Weil <[email protected]>
  • Loading branch information
stweil committed Nov 28, 2021
1 parent 8b21e4f commit 839f528
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 14 deletions.
9 changes: 0 additions & 9 deletions src/ccutil/genericvector.h
Original file line number Diff line number Diff line change
Expand Up @@ -103,9 +103,6 @@ class GenericVector {
// Return the index of the T object.
int get_index(const T &object) const;

// Return true if the index is valid
T contains_index(int index) const;

// Push an element in the end of the array
int push_back(T object);
void operator+=(const T &t);
Expand Down Expand Up @@ -612,12 +609,6 @@ void GenericVector<T>::remove(int index) {
size_used_--;
}

// Return true if the index is valindex
template <typename T>
T GenericVector<T>::contains_index(int index) const {
return index >= 0 && index < size_used_;
}

// Return the index of the T object.
template <typename T>
int GenericVector<T>::get_index(const T &object) const {
Expand Down
5 changes: 0 additions & 5 deletions src/ccutil/unicity_table.h
Original file line number Diff line number Diff line change
Expand Up @@ -69,11 +69,6 @@ class UnicityTable {
return table_.get_index(object);
}

/// Return true if the id is valid
T contains_id(int id) const {
return table_.contains_index(id);
}

/// Add an element in the table
int push_back(T object) {
auto idx = get_index(object);
Expand Down

0 comments on commit 839f528

Please sign in to comment.