@@ -69,7 +69,7 @@ defmodule Module do
69
69
@before_compile A
70
70
end
71
71
72
- * `@behaviour` (notice the british spelling)
72
+ * `@behaviour` (notice the British spelling)
73
73
74
74
Specify an OTP or user-defined behaviour.
75
75
@@ -183,7 +183,7 @@ defmodule Module do
183
183
When just a module is provided, the function is assumed to be
184
184
`__on_definition__/6`.
185
185
186
- Note that you can\ ' t provide the current module to `@on_definition`
186
+ Note that you can't provide the current module to `@on_definition`
187
187
because the hook function will not be defined in time. Finally, since
188
188
the `on_definition` hook is executed inside the context of the defined
189
189
function (i.e. `env.function` returns the current function), the hook
@@ -298,7 +298,7 @@ defmodule Module do
298
298
299
299
In addition to the above, you may also pass to `__info__/1` any atom supported
300
300
by Erlang's `module_info` function which also gets defined for each compiled
301
- module. See http://erlang.org/doc/reference_manual/modules.html#id74571 for
301
+ module. See http://erlang.org/doc/reference_manual/modules.html#id69430 for
302
302
more information.
303
303
"""
304
304
def __info__( kind)
@@ -359,9 +359,9 @@ defmodule Module do
359
359
end
360
360
361
361
@doc """
362
- Creates a module with the given name and given by
362
+ Creates a module with the given name and defined by
363
363
the given quoted expressions. The line where the module
364
- is defined and its file can be given as options.
364
+ is defined and its file can be passed as options.
365
365
366
366
## Examples
367
367
@@ -374,7 +374,7 @@ defmodule Module do
374
374
375
375
Hello.world #=> true
376
376
377
- ## Differences with `defmodule`
377
+ ## Differences from `defmodule`
378
378
379
379
`Module.create` works similarly to `defmodule` and
380
380
return the same results. While one could also use
@@ -398,7 +398,7 @@ defmodule Module do
398
398
end
399
399
400
400
@doc """
401
- Concatenates the list of aliases and returns a new alias.
401
+ Concatenates a list of aliases and returns a new alias.
402
402
403
403
## Examples
404
404
@@ -414,7 +414,7 @@ defmodule Module do
414
414
end
415
415
416
416
@doc """
417
- Concatenates the two given aliases and returns a new alias.
417
+ Concatenates two aliases and returns a new alias.
418
418
419
419
## Examples
420
420
@@ -430,9 +430,9 @@ defmodule Module do
430
430
end
431
431
432
432
@doc """
433
- Concatenates the list aliases and returns a new alias only
433
+ Concatenates a list of aliases and returns a new alias only
434
434
if the alias was already referenced. If the alias was not
435
- referenced yet, fails with ArgumentError.
435
+ referenced yet, fails with ` ArgumentError` .
436
436
It handles char lists, binaries and atoms.
437
437
438
438
## Examples
@@ -450,9 +450,9 @@ defmodule Module do
450
450
end
451
451
452
452
@doc """
453
- Concatenates the two aliases and returns a new alias only
453
+ Concatenates two aliases and returns a new alias only
454
454
if the alias was already referenced. If the alias was not
455
- referenced yet, fails with ArgumentError.
455
+ referenced yet, fails with ` ArgumentError` .
456
456
It handles char lists, binaries and atoms.
457
457
458
458
## Examples
@@ -485,7 +485,7 @@ defmodule Module do
485
485
@doc """
486
486
Attaches documentation to a given function or type. It expects
487
487
the module the function/type belongs to, the line (a non negative
488
- integer), the kind (def or defmacro), a tuple representing
488
+ integer), the kind (` def` or ` defmacro` ), a tuple representing
489
489
the function and its arity, the function signature (the signature
490
490
should be omitted for types) and the documentation, which should
491
491
be either a binary or a boolean.
@@ -584,7 +584,7 @@ defmodule Module do
584
584
585
585
@doc """
586
586
Checks if the module defines the given function or macro.
587
- Use `defines?/3` to assert for an specific type.
587
+ Use `defines?/3` to assert for a specific type.
588
588
589
589
## Examples
590
590
@@ -602,8 +602,8 @@ defmodule Module do
602
602
end
603
603
604
604
@doc """
605
- Checks if the module defines a function or macro with the
606
- given `kind`. `kind` can be either `:def`, `:defp`,
605
+ Checks if the module defines a function or macro of the
606
+ given `kind`. `kind` can be any of `:def`, `:defp`,
607
607
`:defmacro` or `:defmacrop`.
608
608
609
609
## Examples
@@ -625,7 +625,7 @@ defmodule Module do
625
625
end
626
626
627
627
@doc """
628
- Return all functions defined in the given module.
628
+ Return all functions defined in ` module` .
629
629
630
630
## Examples
631
631
@@ -642,7 +642,7 @@ defmodule Module do
642
642
end
643
643
644
644
@doc """
645
- Returns all functions defined in the given module according
645
+ Returns all functions defined in ` module`, according
646
646
to its kind.
647
647
648
648
## Examples
@@ -661,7 +661,7 @@ defmodule Module do
661
661
end
662
662
663
663
@doc """
664
- Makes the given functions in the given module overridable.
664
+ Makes the given functions in ` module` overridable.
665
665
An overridable function is lazily defined, allowing a
666
666
developer to customize it. See `Kernel.defoverridable` for
667
667
more information and documentation.
@@ -694,7 +694,7 @@ defmodule Module do
694
694
end
695
695
696
696
@doc """
697
- Returns true if the given tuple in module is marked as overridable.
697
+ Returns ` true` if ` tuple` in ` module` is marked as overridable.
698
698
"""
699
699
def overridable?(module, tuple) do
700
700
!!List.keyfind(get_attribute(module, :__overridable), tuple, 0)
@@ -789,7 +789,7 @@ defmodule Module do
789
789
end
790
790
791
791
@doc """
792
- Deletes all attributes that matches the given key.
792
+ Deletes all attributes that match the given key.
793
793
794
794
## Examples
795
795
@@ -821,7 +821,7 @@ defmodule Module do
821
821
* `:persist` - The attribute will be persisted in the Erlang
822
822
Abstract Format. Useful when interfacing with Erlang libraries.
823
823
824
- By default, both options are false.
824
+ By default, both options are ` false` .
825
825
826
826
## Examples
827
827
0 commit comments