Skip to content

Commit dc7d7fd

Browse files
author
Zachary Scott
committed
Merge pull request rails#18575 from yui-knk/fix/autoload
[ci skip] fix positions of parentheses
2 parents d6909af + 51f97d0 commit dc7d7fd

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

guides/source/autoloading_and_reloading_constants.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -685,12 +685,12 @@ creates an empty module and assigns it to the `Admin` constant on the fly.
685685
### Generic Procedure
686686

687687
Relative references are reported to be missing in the cref where they were hit,
688-
and qualified references are reported to be missing in their parent. (See
688+
and qualified references are reported to be missing in their parent (see
689689
[Resolution Algorithm for Relative
690690
Constants](#resolution-algorithm-for-relative-constants) at the beginning of
691691
this guide for the definition of *cref*, and [Resolution Algorithm for Qualified
692692
Constants](#resolution-algorithm-for-qualified-constants) for the definition of
693-
*parent*.)
693+
*parent*).
694694

695695
The procedure to autoload constant `C` in an arbitrary situation is as follows:
696696

@@ -868,8 +868,8 @@ end
868868
```
869869

870870
To resolve `User` Ruby checks `Admin` in the former case, but it does not in
871-
the latter because it does not belong to the nesting. (See [Nesting](#nesting)
872-
and [Resolution Algorithms](#resolution-algorithms).)
871+
the latter because it does not belong to the nesting (see [Nesting](#nesting)
872+
and [Resolution Algorithms](#resolution-algorithms)).
873873

874874
Unfortunately Rails autoloading does not know the nesting in the spot where the
875875
constant was missing and so it is not able to act as Ruby would. In particular,
@@ -1284,7 +1284,7 @@ c.user # NameError: uninitialized constant C::User
12841284
```
12851285

12861286
because it detects that a parent namespace already has the constant (see [Qualified
1287-
References](#autoloading-algorithms-qualified-references).)
1287+
References](#autoloading-algorithms-qualified-references)).
12881288

12891289
As with pure Ruby, within the body of a direct descendant of `BasicObject` use
12901290
always absolute constant paths:

0 commit comments

Comments
 (0)