Skip to content

Commit

Permalink
str type: make sentence more readable
Browse files Browse the repository at this point in the history
  • Loading branch information
tshepang authored Jun 28, 2023
1 parent 3b6313a commit 0e2eee4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/types/textual.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ or 0xE000 to 0x10FFFF range. It is immediate [Undefined Behavior] to create a
`char` that falls outside this range. A `[char]` is effectively a UCS-4 / UTF-32
string of length 1.

A value of type `str` is represented the same way as `[u8]`, it is a slice of
A value of type `str` is represented the same way as `[u8]`, a slice of
8-bit unsigned bytes. However, the Rust standard library makes extra assumptions
about `str`: methods working on `str` assume and ensure that the data in there
is valid UTF-8. Calling a `str` method with a non-UTF-8 buffer can cause
Expand Down

0 comments on commit 0e2eee4

Please sign in to comment.