Skip to content

Commit 6c84492

Browse files
committed
Fixed doc typos in Kernel and String
1 parent b1d2456 commit 6c84492

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

lib/elixir/lib/kernel.ex

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2407,7 +2407,7 @@ defmodule Kernel do
24072407
24082408
Enum.map(List.flatten([1, [2], 3]), &(&1 * 2))
24092409
2410-
Be aware of operator precendence when using this operator.
2410+
Be aware of operator precedence when using this operator.
24112411
For example, the following expression:
24122412
24132413
String.graphemes "Hello" |> Enum.reverse
@@ -3565,7 +3565,7 @@ defmodule Kernel do
35653565
## Sigils
35663566

35673567
@doc """
3568-
Handles the sigil %S. It simples returns a string
3568+
Handles the sigil %S. It simply returns a string
35693569
without escaping characters and without interpolations.
35703570
35713571
## Examples
@@ -3613,7 +3613,7 @@ defmodule Kernel do
36133613
end
36143614

36153615
@doc """
3616-
Handles the sigil %c. It returns a char list as if it was a single
3616+
Handles the sigil %c. It returns a char list as if it were a single
36173617
quoted string, unescaping characters and replacing interpolations.
36183618
36193619
## Examples

lib/elixir/lib/string.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -497,7 +497,7 @@ defmodule String do
497497
"a-b,c"
498498
499499
The pattern can also be a regex. In those cases, one can give `\N`
500-
in the `replacement` string to access a specific catpure in the regex:
500+
in the `replacement` string to access a specific capture in the regex:
501501
502502
iex> String.replace("a,b,c", %r/,(.)/, ",\\1\\1")
503503
"a,bb,cc"

0 commit comments

Comments
 (0)