Skip to content

Commit aefcd5c

Browse files
authored
Merge pull request #1667 from ehuss/fix-header-link
Update some "default" representation references
2 parents ba3ca44 + 1317a75 commit aefcd5c

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

src/items/enumerations.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ Each enum instance has a _discriminant_: an integer logically associated to it
133133
that is used to determine which variant it holds.
134134

135135
r[items.enum.discriminant.repr-rust]
136-
Under the [default representation], the discriminant is interpreted as
136+
Under the [`Rust` representation], the discriminant is interpreted as
137137
an `isize` value. However, the compiler is allowed to use a smaller type (or
138138
another means of distinguishing variants) in its actual memory layout.
139139

@@ -378,14 +378,14 @@ enum E {
378378
[`C` representation]: ../type-layout.md#the-c-representation
379379
[call expression]: ../expressions/call-expr.md
380380
[constant expression]: ../const_eval.md#constant-expressions
381-
[default representation]: ../type-layout.md#the-default-representation
382381
[enumerated type]: ../types/enum.md
383382
[Field-less enums]: #field-less-enum
384383
[IDENTIFIER]: ../identifiers.md
385384
[never type]: ../types/never.md
386385
[numeric cast]: ../expressions/operator-expr.md#semantics
387386
[path expression]: ../expressions/path-expr.md
388387
[primitive representation]: ../type-layout.md#primitive-representations
388+
[`Rust` representation]: ../type-layout.md#the-rust-representation
389389
[struct expression]: ../expressions/struct-expr.md
390390
[struct]: structs.md
391391
[type namespace]: ../names/namespaces.md

src/type-layout.md

+3-2
Original file line numberDiff line numberDiff line change
@@ -204,10 +204,11 @@ struct AlignedStruct {
204204
r[layout.repr.inter-field]
205205
The representation of a type can change the padding between fields, but does
206206
not change the layout of the fields themselves. For example, a struct with a
207-
`C` representation that contains a struct `Inner` with the default
207+
`C` representation that contains a struct `Inner` with the `Rust`
208208
representation will not change the layout of `Inner`.
209209

210-
### <a id="the-default-representation"></a> The `Rust` Representation
210+
<a id="the-default-representation"></a>
211+
### The `Rust` Representation
211212

212213
r[layout.repr.rust]
213214

0 commit comments

Comments
 (0)