Skip to content

Commit 6703e91

Browse files
committed
[.clang-format] Init @ root
1 parent 7059eeb commit 6703e91

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

.clang-format

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# Run manually to reformat a file:
2+
# clang-format -i --style=file <file>
3+
BasedOnStyle: Google
4+
DerivePointerAlignment: false

tensorflow/compiler/xla/python/types.h

+1
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,7 @@ pybind11::tuple SpanToTuple(absl::Span<int64_t const> xs);
118118
template <typename T>
119119
std::vector<T> IterableToVector(const pybind11::iterable& iterable) {
120120
std::vector<T> output;
121+
output.reserve(std::distance(iterable.begin(), iterable.end()));
121122
for (auto item : iterable) {
122123
output.push_back(item.cast<T>());
123124
}

0 commit comments

Comments
 (0)