@@ -21,9 +21,9 @@ defmodule Kernel.Typespec do
2121 expressed the same way: `pid()` or simply `pid`. Parametrized types are also
2222 supported (`list(integer`) and so are remote types (`Enum.t`).
2323
24- For integers and atoms literals are allowed as types (ex. `1`, `:atom` or
25- `false`). All other types are built up of unions of predefined types. Certain
26- shorthands are allowed, such as `[...]`, `<<>>` and `{...}`) .
24+ Integers and atom literals are allowed as types (ex. `1`, `:atom` or
25+ `false`). All other types are built of unions of predefined types. Certain
26+ shorthands are allowed, such as `[...]`, `<<>>` and `{...}`.
2727
2828 ### Predefined types
2929
@@ -57,17 +57,17 @@ defmodule Kernel.Typespec do
5757
5858 Integer :: integer
5959 | ElixirInteger # ..., -1, 0, 1, ... 42 ...
60- | ElixirInteger..ElixirInteger # specifies an integer range
60+ | ElixirInteger..ElixirInteger # an integer range
6161
6262 List :: list(Type) # proper list ([]-terminated)
6363 | improper_list(Type1, Type2) # Type1=contents, Type2=termination
6464 | maybe_improper_list(Type1, Type2) # Type1 and Type2 as above
6565 | nonempty_list(Type) # proper non-empty list
6666 | [] # empty list
6767 | [Type] # shorthand for list(Type)
68- | [Type, ...] # sharthand for nonempty_list(Type)
68+ | [Type, ...] # shorthand for nonempty_list(Type)
6969
70- Tuple :: tuple # stands for a tuple of any size
70+ Tuple :: tuple # a tuple of any size
7171 | {} # empty tuple
7272 | { TList }
7373
@@ -185,13 +185,13 @@ defmodule Kernel.Typespec do
185185 use the `char_list` type which is a synonym for `string`. If you use `string`,
186186 you'll get a warning from the compiler.
187187
188- If you want to refer to the "string" type (the one operated by functions in
189- the String module), use `String.t` type instead.
188+ If you want to refer to the "string" type (the one operated on by functions in
189+ the ` String` module), use `String.t` type instead.
190190 """
191191
192192 @ doc """
193193 Defines a type.
194- This macro is the one responsible for handling the attribute `@type`.
194+ This macro is responsible for handling the attribute `@type`.
195195
196196 ## Examples
197197
@@ -206,7 +206,7 @@ defmodule Kernel.Typespec do
206206
207207 @ doc """
208208 Defines an opaque type.
209- This macro is the one responsible for handling the attribute `@opaque`.
209+ This macro is responsible for handling the attribute `@opaque`.
210210
211211 ## Examples
212212
@@ -221,7 +221,7 @@ defmodule Kernel.Typespec do
221221
222222 @ doc """
223223 Defines a private type.
224- This macro is the one responsible for handling the attribute `@typep`.
224+ This macro is responsible for handling the attribute `@typep`.
225225
226226 ## Examples
227227
@@ -236,7 +236,7 @@ defmodule Kernel.Typespec do
236236
237237 @ doc """
238238 Defines a spec.
239- This macro is the one responsible for handling the attribute `@spec`.
239+ This macro is responsible for handling the attribute `@spec`.
240240
241241 ## Examples
242242
@@ -251,7 +251,7 @@ defmodule Kernel.Typespec do
251251
252252 @ doc """
253253 Defines a callback.
254- This macro is the one responsible for handling the attribute `@callback`.
254+ This macro is responsible for handling the attribute `@callback`.
255255
256256 ## Examples
257257
@@ -408,10 +408,10 @@ defmodule Kernel.Typespec do
408408 @ doc """
409409 Returns all type docs available from the module's beam code.
410410
411- It is returned as a list of tuples where the first element is the pair of type
411+ The result is returned as a list of tuples where the first element is the pair of type
412412 name and arity and the second element is the documentation.
413413
414- The module has to have a corresponding beam file on the disk which can be
414+ The module must have a corresponding beam file which can be
415415 located by the runtime system.
416416 """
417417 @ spec beam_typedocs ( module | binary ) :: [ tuple ] | nil
@@ -428,10 +428,10 @@ defmodule Kernel.Typespec do
428428 @ doc """
429429 Returns all types available from the module's beam code.
430430
431- It is returned as a list of tuples where the first
431+ The result is returned as a list of tuples where the first
432432 element is the type (`:typep`, `:type` and `:opaque`).
433433
434- The module has to have a corresponding beam file on the disk which can be
434+ The module must have a corresponding beam file which can be
435435 located by the runtime system.
436436 """
437437 @ spec beam_types ( module | binary ) :: [ tuple ] | nil
@@ -456,10 +456,10 @@ defmodule Kernel.Typespec do
456456 @ doc """
457457 Returns all specs available from the module's beam code.
458458
459- It is returned as a list of tuples where the first
459+ The result is returned as a list of tuples where the first
460460 element is spec name and arity and the second is the spec.
461461
462- The module has to have a corresponding beam file on the disk which can be
462+ The module must have a corresponding beam file which can be
463463 located by the runtime system.
464464 """
465465 @ spec beam_specs ( module | binary ) :: [ tuple ] | nil
@@ -470,10 +470,10 @@ defmodule Kernel.Typespec do
470470 @ doc """
471471 Returns all callbacks available from the module's beam code.
472472
473- It is returned as a list of tuples where the first
473+ The result is returned as a list of tuples where the first
474474 element is spec name and arity and the second is the spec.
475475
476- The module has to have a corresponding beam file on the disk
476+ The module must have a corresponding beam file
477477 which can be located by the runtime system.
478478 """
479479 @ spec beam_callbacks ( module | binary ) :: [ tuple ] | nil
0 commit comments