[backport] Fix spelling typos (#12755)

This commit is contained in:
Brian Wignall 2019-11-28 02:30:55 -05:00 • committed by Miran
commit a7aeabb9d2
10 changed files with 18 additions and 18 deletions

View file

@ -1644,7 +1644,7 @@ object branch, the initialization is considered valid. This analysis only works
for immutable discriminators of an ordinal type and disregards ``elif``
branches. For discriminator values with a ``range`` type, the compiler
checks if the entire range of possible values for the discriminator value is
valid for the choosen object branch.
valid for the chosen object branch.
A small example:
@ -3440,14 +3440,14 @@ different; for this a special setter syntax is needed:
## setter of hostAddr.
## This accesses the 'host' field and is not a recursive call to
## ``host=`` because the builtin dot access is preferred if it is
## avaliable:
## available:
s.host = value
proc host*(s: Socket): int {.inline.} =
## getter of hostAddr
## This accesses the 'host' field and is not a recursive call to
## ``host`` because the builtin dot access is preferred if it is
## avaliable:
## available:
s.host
.. code-block:: nim
@ -5409,7 +5409,7 @@ expression by coercing it to a corresponding ``static`` type:
echo static(fac(5)), " ", static[bool](16.isPowerOfTwo)
The complier will report any failure to evaluate the expression or a
The compiler will report any failure to evaluate the expression or a
possible type mismatch error.
typedesc[T]
@ -5421,7 +5421,7 @@ all values must have a type, ``typedesc`` is considered their special type.
``typedesc`` acts like a generic type. For instance, the type of the symbol
``int`` is ``typedesc[int]``. Just like with regular generic types, when the
generic param is ommited, ``typedesc`` denotes the type class of all types.
generic param is omitted, ``typedesc`` denotes the type class of all types.
As a syntactic convenience, you can also use ``typedesc`` as a modifier.
Procs featuring ``typedesc`` params are considered implicitly generic.