Skip to content

Commit 41ca263

Browse files
committed
Fix "Line must not end with spaces" and link error
1 parent 900ee93 commit 41ca263

File tree

3 files changed

+8
-12
lines changed

3 files changed

+8
-12
lines changed

src/types/numeric.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ r[type.numeric.repr.integer-width]
7070
The range of values an integer type can represent depends on its signedness and its width, in bits. The width of type `uN` or `iN` is `N`. The width of type `usize` or `isize` is the value of the `target_pointer_width` property.
7171

7272
> [!NOTE]
73-
> There are exactly `1<<N` unique values of an integer type of width `N`.
73+
> There are exactly `1<<N` unique values of an integer type of width `N`.
7474
> In particular, for an unsigned type, these values are in the range `0..(1<<N)` and for a signed type, are in the range `-(1<<(N-1))..(1<<(N-1))`, using rust range syntax.
7575
7676
r[type.numeric.repr.unsigned]
@@ -88,19 +88,19 @@ r[type.numeric.repr.signed]
8888
A value `i` of a signed integer type with width `N` is represented the same as the corresponding value of the unsigned counterpart type which is congruent modulo `2^N`.
8989

9090
> [!NOTE]
91-
> This encoding of signed integers is known as the 2s complement encoding.
91+
> This encoding of signed integers is known as the 2s complement encoding.
9292
9393
r[type.numeric.repr.float-width]
9494
Each floating-point type has a width. The type `fN` has a width of `N`.
9595

9696
r[type.numeric.repr.float]
9797
A floating-point value is represented by the following decoding:
9898
* The byte sequence is decoded as the unsigned integer type with the same width as the floating-point type,
99-
* The resulting integer is decoded according to [IEEE 754-2019] into the format used for the type.
99+
* The resulting integer is decoded according to [IEEE 754-2019] into the format used for the type.
100100

101101
> [!NOTE]
102-
> The representation of each finite number and infinity is unique as a result of this.
103-
> The exact behaviour of encoding and decoding NaNs is not yet decided
102+
> The representation of each finite number and infinity is unique as a result of the definition of [IEEE 754-2019].
103+
> The exact behaviour of encoding and decoding NaNs is not yet decided
104104
105105
r[type.numeric.repr.float-format]
106106
The [IEEE 754-2019] `binary32` format is used for `f32`, and the `binary64` format is used for `f64`. The set of values for each floating-point type are determined by the respective format.

src/types/struct.md

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -36,13 +36,9 @@ r[type.struct.value]
3636
r[type.struct.value.intro]
3737
A value of a struct type consists of a list of values for each field.
3838

39-
4039
r[type.struct.value.encode-decode]
4140
When a value of a struct type is encoded, each field of the struct is encoded at its corresponding offset and each byte that is not within a field of the struct is set to uninit.
42-
When a value of a struct type is decoded, each field of the struct is decoded from its corresponding offset.
43-
44-
> [!NOTE]
45-
> It is valid for padding bytes to hold a value other than uninit when decoded, and these bytes are ignored when decoding an struct value.
41+
When a value of a struct type is decoded, each field of the struct is decoded from its corresponding offset. Each byte that is not within a field of the struct is ignored.
4642

4743
[^structtype]: `struct` types are analogous to `struct` types in C, the
4844
*record* types of the ML family, or the *struct* types of the Lisp family.

src/types/union.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ The memory layout of a `union` is undefined by default (in particular, fields do
2424
*not* have to be at offset 0), but the `#[repr(...)]` attribute can be used to
2525
fix a layout.
2626

27-
## Union Values
27+
## Union Values
2828

2929
r[type.union.value]
3030

@@ -37,7 +37,7 @@ A byte `b` in the representation of a struct or union is a value byte if there e
3737
> [!NOTE]
3838
> A byte in a union is a value byte if it is a value byte in *any* field.
3939
40-
r[type.struct.value.padding]
40+
r[type.union.value.padding]
4141
Every byte in an struct or union which is not a value byte is a padding byte. [Enum types][type.enum.value.value-padding], [tuple types][type.tuple.padding], and other types may also have padding bytes.
4242

4343
> [!NOTE]

0 commit comments

Comments
 (0)