Skip to content

Commit 0bf28c1

Browse files
authored
Update 04-containers.md
1 parent 51f05d4 commit 0bf28c1

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎book/en-us/04-containers.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,7 @@ You can have a `variant<>` to accommodate several types of variables provided (i
246246
template <size_t n, typename... T>
247247
constexpr std::variant<T...> _tuple_index(const std::tuple<T...>& tpl, size_t i) {
248248
if constexpr (n >= sizeof...(T))
249-
throw std::out_of_range("越界.");
249+
throw std::out_of_range("tuple index out of range.");
250250
if (i == n)
251251
return std::variant<T...>{ std::in_place_index<n>, std::get<n>(tpl) };
252252
return _tuple_index<(n < sizeof...(T)-1 ? n+1 : 0)>(tpl, i);

0 commit comments

Comments
 (0)