fix RFC #341: dot-like operators are now parsed with same precedence as . (#18711)

* fix RFC #341: dot-like operators are now parsed with same precedence as `.`

* fixup

* [skip ci] address comment in changelog

* address comment

* update grammmar

* add manual entry

* fixup

* -d:nimPreviewDotLikeOps

* address comment to unblock PR: move nimPreviewDotLikeOps out of config/config.nims
This commit is contained in:
Timothee Cour 2021-08-24 21:50:40 -07:00 • committed by GitHub
commit 3aa16c1de0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 74 additions and 5 deletions

View file

@ -104,6 +104,10 @@
- In `std/dom`, `Interval` is now a `ref object`, same as `Timeout`. Definitions of `setTimeout`,
`clearTimeout`, `setInterval`, `clearInterval` were updated.
- With `-d:nimPreviewDotLikeOps` (default in devel), dot-like operators (operators starting with `.`, but not with `..`)
now have the same precedence as `.`, so that `a.?b.c` is now parsed as `(a.?b).c` instead of `a.?(b.c)`.
A warning is generated when a dot-like operator is used without `-d:nimPreviewDotLikeOps`.
- The allocator for Nintendo Switch, which was nonfunctional because
of breaking changes in libnx, was removed, in favour of the new `-d:nimAllocPagesViaMalloc` option.