implemented Unicode operators (#18789)
* implemented Unicode operators; refs https://github.com/nim-lang/RFCs/issues/388 * bugfix * better test * arguably more elegant implementation * Update changelog.md Co-authored-by: konsumlamm <44230978+konsumlamm@users.noreply.github.com> Co-authored-by: konsumlamm <44230978+konsumlamm@users.noreply.github.com>
This commit is contained in:
parent
905fae51f6
commit
c2b20516d3
6 changed files with 117 additions and 7 deletions
|
|
@ -445,6 +445,13 @@ proc mysort(s: seq; cmp: proc(a, b: T): int) {.effectsOf: cmp.}
|
|||
To enable the new effect system, use --experimental:strictEffects.
|
||||
|
||||
|
||||
- Nim now supports a small subset of Unicode operators as operator symbols.
|
||||
The supported symbols are: "∙ ∘ × ★ ⊗ ⊘ ⊙ ⊛ ⊠ ⊡ ∩ ∧ ⊓ ± ⊕ ⊖ ⊞ ⊟ ∪ ∨ ⊔".
|
||||
To enable this feature, use `--experimental:unicodeOperators`. Note that due
|
||||
to parser limitations you **cannot** enable this feature via a
|
||||
pragma `{.experimental: "unicodeOperators".}` reliably.
|
||||
|
||||
|
||||
## Compiler changes
|
||||
|
||||
- Added `--declaredLocs` to show symbol declaration location in messages.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue