Make more use of llvm STLExtras (#4668)

This is essentially the result of looking at `.begin()` uses. We also
frequently do `std::shuffle`, but unfortunately STLExtras doesn't
provide a wrapper for that.
This commit is contained in:
Jon Ross-Perkins
2024-12-11 18:16:38 +00:00
committed by GitHub
parent 47285b6207
commit 61c0a8b676
15 changed files with 52 additions and 64 deletions
+1 -1
View File
@@ -78,7 +78,7 @@ class ArrayStack {
auto AppendToTop(llvm::ArrayRef<ValueT> values) -> void {
CARBON_CHECK(!array_offsets_.empty(),
"Must call PushArray before PushValues.");
values_.append(values.begin(), values.end());
llvm::append_range(values_, values);
}
// Returns the current number of values in all arrays.