Skip to content

Commit 32f6e89

Browse files
brettcannonmichalmuskala
authored andcommitted
Harmonize the wording of two sentences (elixir-lang#1198)
"a list of integers representing bytes or binaries" compared to "a list of characters or strings" in two adjacent paragraphs is slightly jarring. Changing both to "or" makes the comparison/transition easier to read.
1 parent 89b05c9 commit 32f6e89

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

getting-started/io-and-the-file-system.markdown

+1-1
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ hello world
163163
:ok
164164
```
165165

166-
However, using lists in IO operations requires some attention. A list may represent either a bunch of bytes or a bunch of characters and which one to use depends on the encoding of the IO device. If the file is opened without encoding, the file is expected to be in raw mode, and the functions in the `IO` module starting with `bin*` must be used. Those functions expect an `iodata` as an argument; i.e., they expect a list of integers representing bytes and binaries to be given.
166+
However, using lists in IO operations requires some attention. A list may represent either a bunch of bytes or a bunch of characters and which one to use depends on the encoding of the IO device. If the file is opened without encoding, the file is expected to be in raw mode, and the functions in the `IO` module starting with `bin*` must be used. Those functions expect an `iodata` as an argument; i.e., they expect a list of integers representing bytes or binaries to be given.
167167

168168
On the other hand, `:stdio` and files opened with `:utf8` encoding work with the remaining functions in the `IO` module. Those functions expect a `char_data` as an argument, that is, a list of characters or strings.
169169

0 commit comments

Comments
 (0)