Make random.rand work with Ordinal (#20043)

* Make `random.rand` work with `Ordinal`

* Add changelog entry

* It's fine to cast to char
This commit is contained in:
Amjad Ben Hedhili 2022-07-16 21:51:27 +01:00 • committed by GitHub
commit cf78c02b70
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 6 deletions

View file

@ -39,6 +39,7 @@ becomes an alias for `addr`.
- `std/smtp` sends `ehlo` first. If the mail server does not understand, it sends `helo` as a fallback.
- Changed mimedb to use an `OrderedTable` instead of `OrderedTableRef`, to use it in a const.
- `strutils.find` now use and default to `last=-1` for whole string searches, making limiting it to just the first char (`last=0`) valid.
- `random.rand` now works with `Ordinal`s.
[//]: # "Additions:"
- Added `IsoWeekRange`, a range type to represent the number of weeks in an ISO week-based year.