@@ -53,12 +53,13 @@ This file consists of three conceptual sections:
53
53
3. Minor utility functions
54
54
55
55
56
- ## Recursive Types Some kinds of types, such as structs and enums can be
57
- recursive. That means that the type definition of some type X refers to some
58
- other type which in turn (transitively) refers to X. This introduces cycles into
59
- the type referral graph. A naive algorithm doing an on-demand, depth-first
60
- traversal of this graph when describing types, can get trapped in an endless
61
- loop when it reaches such a cycle.
56
+ ## Recursive Types
57
+
58
+ Some kinds of types, such as structs and enums can be recursive. That means that
59
+ the type definition of some type X refers to some other type which in turn (transitively)
60
+ refers to X. This introduces cycles into the type referral graph. A naive algorithm doing
61
+ an on-demand, depth-first traversal of this graph when describing types, can get trapped
62
+ in an endless loop when it reaches such a cycle.
62
63
63
64
For example, the following simple type for a singly-linked list...
64
65
@@ -96,10 +97,12 @@ traversal at the type members after the type has been registered with the cache.
96
97
the future)
97
98
98
99
99
- ## Source Locations and Line Information In addition to data type descriptions
100
- the debugging information must also allow to map machine code locations back to
101
- source code locations in order to be useful. This functionality is also handled
102
- in this module. The following functions allow to control source mappings:
100
+ ## Source Locations and Line Information
101
+
102
+ In addition to data type descriptions the debugging information must also allow
103
+ to map machine code locations back to source code locations in order to be useful.
104
+ This functionality is also handled in this module. The following functions allow
105
+ to control source mappings:
103
106
104
107
+ set_source_location()
105
108
+ clear_source_location()
@@ -139,10 +142,12 @@ of the prologue, however, they are ignored by LLVM's prologue detection. The
139
142
source location emission is still disabled, so there is no need to do anything
140
143
special with source location handling here.
141
144
142
- ## Unique Type Identification In order for link-time optimization to work
143
- properly, LLVM needs a unique type identifier that tells it across compilation
144
- units which types are the same as others. This type identifier is created by
145
- TypeMap::get_unique_type_id_of_type() using the following algorithm:
145
+ ## Unique Type Identification
146
+
147
+ In order for link-time optimization to work properly, LLVM needs a unique type
148
+ identifier that tells it across compilation units which types are the same as
149
+ others. This type identifier is created by TypeMap::get_unique_type_id_of_type()
150
+ using the following algorithm:
146
151
147
152
(1) Primitive types have their name as ID
148
153
(2) Structs, enums and traits have a multipart identifier
0 commit comments