Skip to content

Commit e3cadc4

Browse files
author
mikeblome
committed
fixed link
1 parent 2e81351 commit e3cadc4

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎docs/standard-library/basic-string-view-class.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ A const_reference to the character at the position specified by the parameter in
162162
163163
### Remarks
164164
165-
The first element has an index of zero and the following elements are indexed consecutively by the positive integers, so that a string_view of length *n* has an *n*th element indexed by the number *n -* 1. **at** throws an exception for invalid indices, unlike [operator\[\]](#op_).
165+
The first element has an index of zero and the following elements are indexed consecutively by the positive integers, so that a string_view of length *n* has an *n*th element indexed by the number *n -* 1. **at** throws an exception for invalid indices, unlike [operator\[\]](#op_at).
166166
167167
In general, we recomend that **at** for sequences such as `std::vector` and string_view should never be used. An invalid index passed to a sequence is a logic error that should be discovered and fixed during development. If a program isn't absolutely certain that its indices are valid, it should test them, not call at() and rely on exceptions to defend against careless programming.
168168

0 commit comments

Comments
 (0)