Skip to content

Commit

Permalink
Fix type expressed in last example of specs' Floating-point numbers (…
Browse files Browse the repository at this point in the history
…fixes 370) (google#371)

According to the specs, aithmetic operations applied to a mixture of `float`
and `int` operands should result in a `float` value. However, the example
`3.0 // 2.0` had the value `1` commented beside it, which could imply
that its type is `int`. For clarity this mistake was fixed.
  • Loading branch information
Algebra8 authored Apr 29, 2021
1 parent 1607a96 commit 0c63ff3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion doc/spec.md
Original file line number Diff line number Diff line change
Expand Up @@ -618,7 +618,7 @@ non-zero.
3.0 / 2 # 1.5
3 / 2.0 # 1.5
float(3) / 2 # 1.5
3.0 // 2.0 # 1
3.0 // 2.0 # 1.0
```

### Strings
Expand Down

0 comments on commit 0c63ff3

Please sign in to comment.