From 6c844926187925000baa3f4364ec20582cd145b7 Mon Sep 17 00:00:00 2001 From: John Warwick Date: Sun, 15 Dec 2013 14:19:07 +0100 Subject: [PATCH] Fixed doc typos in Kernel and String --- lib/elixir/lib/kernel.ex | 6 +++--- lib/elixir/lib/string.ex | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/elixir/lib/kernel.ex b/lib/elixir/lib/kernel.ex index 41fbaf5c856..7273470f677 100644 --- a/lib/elixir/lib/kernel.ex +++ b/lib/elixir/lib/kernel.ex @@ -2407,7 +2407,7 @@ defmodule Kernel do Enum.map(List.flatten([1, [2], 3]), &(&1 * 2)) - Be aware of operator precendence when using this operator. + Be aware of operator precedence when using this operator. For example, the following expression: String.graphemes "Hello" |> Enum.reverse @@ -3565,7 +3565,7 @@ defmodule Kernel do ## Sigils @doc """ - Handles the sigil %S. It simples returns a string + Handles the sigil %S. It simply returns a string without escaping characters and without interpolations. ## Examples @@ -3613,7 +3613,7 @@ defmodule Kernel do end @doc """ - Handles the sigil %c. It returns a char list as if it was a single + Handles the sigil %c. It returns a char list as if it were a single quoted string, unescaping characters and replacing interpolations. ## Examples diff --git a/lib/elixir/lib/string.ex b/lib/elixir/lib/string.ex index 437ebc11fef..7a42840f264 100644 --- a/lib/elixir/lib/string.ex +++ b/lib/elixir/lib/string.ex @@ -497,7 +497,7 @@ defmodule String do "a-b,c" The pattern can also be a regex. In those cases, one can give `\N` - in the `replacement` string to access a specific catpure in the regex: + in the `replacement` string to access a specific capture in the regex: iex> String.replace("a,b,c", %r/,(.)/, ",\\1\\1") "a,bb,cc"