Skip to content

Commit e30d515

Browse files
authored
Merge pull request #929 from Havvy/float-literal-example
Add a float examle without a `.`.
2 parents 3e93fea + 8e62ab3 commit e30d515

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/tokens.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -509,6 +509,7 @@ Examples of floating-point literals of various forms:
509509
0.1f64; // type f64
510510
0.1f32; // type f32
511511
12E+99_f64; // type f64
512+
5f32; // type f32
512513
let x: f64 = 2.; // type f64
513514
```
514515

@@ -517,9 +518,7 @@ syntax with a floating point literal ending in a period. `2.f64` would attempt
517518
to call a method named `f64` on `2`.
518519

519520
The representation semantics of floating-point numbers are described in
520-
["Machine Types"].
521-
522-
["Machine Types"]: types/numeric.md
521+
["Machine Types"][machine types].
523522

524523
### Boolean literals
525524

@@ -637,6 +636,7 @@ them are referred to as "token trees" in [macros]. The three types of brackets
637636
[if let]: expressions/if-expr.md#if-let-expressions
638637
[keywords]: keywords.md
639638
[lazy-bool]: expressions/operator-expr.md#lazy-boolean-operators
639+
[machine types]: types/numeric.md
640640
[macros]: macros-by-example.md
641641
[match]: expressions/match-expr.md
642642
[negation]: expressions/operator-expr.md#negation-operators

0 commit comments

Comments
 (0)