mirror of
https://github.com/licsber/micropython.git
synced 2024-09-20 09:00:23 +08:00
py/obj: Optimise small-int comparison to 0 in mp_obj_is_true.
Instead of converting to a small-int at runtime this can be done at compile time, then we only have a simple comparison during runtime. This reduces code size on some ports (e.g -4 on qemu-arm, -52 on unix nanbox), and for others at least doesn't increase code size.
This commit is contained in:
parent
faf3d3e9e9
commit
7cf26ca4bd
Loading…
Reference in New Issue
Block a user