-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[mypyc] Support the u8 native integer type (#15564)
This is mostly similar to `i16` that I added recently in #15464, but there are some differences: * Some adjustments were needed to support unsigned integers * Add overflow checking of literals, since it's easy to over/underflow when using `u8` due to limited range * Rename primitive integer types from `int16` to `i16` (etc.) to match the user-visible types (needed to get some error messages consistent, and it's generally nicer) * Overall make things a bit more consistent * Actually update `mypy_extensions` stubs This is an unsigned type to make it easier to work with binary/bytes data. The item values for `bytes` are unsigned 8-bit values, in particular. This type will become much more useful once we support packed arrays. --------- Co-authored-by: Shantanu <[email protected]>
- Loading branch information
1 parent
e0b159e
commit 8c70e80
Showing
50 changed files
with
1,843 additions
and
634 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.