Skip to content

Commit 375e799

Browse files
committed
Fix some typos
1 parent 92a0f37 commit 375e799

File tree

6 files changed

+9
-9
lines changed

6 files changed

+9
-9
lines changed

advanced-constructs/generators.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ that the function's state is preserved across the repeated calls of the
66
function; this includes the function's local offset at the point it
77
yielded a value.
88

9-
The most straigthforward way to implement a generator is by wrapping all
9+
The most straightforward way to implement a generator is by wrapping all
1010
of its state variables (arguments, local variables, and return values)
1111
up into an ad-hoc structure and then pass the address of that structure
1212
to the generator.
@@ -24,7 +24,7 @@ The important thing is to think of iterators as a sort of micro-thread
2424
that is resumed whenever the iterator is called again. In other words,
2525
we need to save the address of how far the iterator got on each pass
2626
through so that it can resume as if a microscopic thread switch had
27-
occured. So we save the address of the instruction after the return
27+
occurred. So we save the address of the instruction after the return
2828
instruction so that we can resume running as if we never had returned in
2929
the first place.
3030

appendix-a-how-to-implement-a-string-type-in-llvm/index.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ There are two ways to implement a string type in LLVM:
1010
I'd personally much prefer to use the second method, but for the sake of
1111
the example, I'll go ahead and illustrate a simple but useful string
1212
type in LLVM IR. It assumes a 32-bit architecture, so please replace all
13-
occurences of ``i32`` with ``i64`` if you are targetting a 64-bit
13+
occurrences of ``i32`` with ``i64`` if you are targeting a 64-bit
1414
architecture.
1515

1616
We'll be making a dynamic, mutable string type that can be appended to

basic-constructs/functions.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ Functions with a Variable Number of Parameters
7272

7373
To call a so-called vararg function, you first need to define or declare
7474
it using the elipsis (...) and then you need to make use of a special
75-
syntax for function calls that allows you to explictly list the types of
75+
syntax for function calls that allows you to explicitly list the types of
7676
the parameters of the function that is being called. This "hack" exists
7777
to allow overriding a call to a function such as a function with
7878
variable parameters. Please notice that you only need to specify the
@@ -184,9 +184,9 @@ This simple example is in turn compiled to
184184
ret void
185185
}
186186
187-
We can see that the funtion now actually returns ``void`` and another
187+
We can see that the function now actually returns ``void`` and another
188188
parameter was added. The first parameter is a pointer to the result,
189-
which is allocated by the caller. The pointer has the attirbute
189+
which is allocated by the caller. The pointer has the attribute
190190
``noalias`` because there is no way that one of the parameters might
191191
point to the same location. The ``sret`` attribute indicates that this
192192
is the return value.

basic-constructs/global-variables.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Global Variables
22
----------------
33

4-
Global varibles are trivial to implement in LLVM IR:
4+
Global variables are trivial to implement in LLVM IR:
55

66
.. code-block:: cpp
77

object-oriented-constructs/multiple-inheritance.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ This is equivalent to the following LLVM IR:
8989
}
9090
9191
And the compiler then supplies the needed type casts and pointer
92-
arithmentic whenever ``baseB`` is being referenced as an instance
92+
arithmetic whenever ``baseB`` is being referenced as an instance
9393

9494
of ``BaseB``. Please notice that all it takes is a ``bitcast`` from one
9595
class to another as well as an adjustment of the last argument to

object-oriented-constructs/virtual-inheritance.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ Virtual Inheritance
22
-------------------
33

44
Virtual inheritance is actually quite simple as it dictates that
5-
identical base classes are to be merged into a single occurence. For
5+
identical base classes are to be merged into a single occurrence. For
66
instance, given this:
77

88
.. code-block:: cpp

0 commit comments

Comments
 (0)