make unary minus part of number literals, refs #17020 (#17488)

* make unary minus part of number literals, refs #17020
* fixes regression
This commit is contained in:
Andreas Rumpf 2021-03-24 09:47:11 +01:00 • committed by GitHub
commit 86af2f7b50
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 173 additions and 39 deletions

View file

@ -212,7 +212,7 @@
- `std/options` changed `$some(3)` to `"some(3)"` instead of `"Some(3)"`
and `$none(int)` to `"none(int)"` instead of `"None[int]"`.
- Added `algorithm.merge`.
@ -263,6 +263,8 @@
- `typedesc[Foo]` now renders as such instead of `type Foo` in compiler messages.
- The unary minus in `-1` is now part of the integer literal, it is now parsed as a single token.
This implies that edge cases like `-128'i8` finally work correctly.
## Compiler changes