136 Commits (be6464121072e827eefa19d7ae12746612a8cb79)

Author SHA1 Message Date
Damien George 69dd013919 py/objint: Allow int() to parse anything with the buffer protocol. 1 year ago
Damien George 48ffd6596e py: Change MP_UNARY_OP_INT to MP_UNARY_OP_INT_MAYBE. 1 year ago
Jim Mussared 94beeabd2e py/obj: Convert make_new into a mp_obj_type_t slot. 2 years ago
Jim Mussared 9dce82776d all: Remove unnecessary locals_dict cast. 2 years ago
Jim Mussared 662b9761b3 all: Make all mp_obj_type_t defs use MP_DEFINE_CONST_OBJ_TYPE. 3 years ago
Jim Mussared 8a0ee5a5c0 py/objstr: Split mp_obj_str_from_vstr into bytes/str versions. 2 years ago
Yonatan Goldschmidt 2a6ba47110 py/obj: Add static safety checks to mp_obj_is_type(). 5 years ago
Jeff Epler 413f34cd8f all: Fix signed shifts and NULL access errors from -fsanitize=undefined. 3 years ago
Damien George 7e956fae28 py: Rename BITS_PER_BYTE to MP_BITS_PER_BYTE. 4 years ago
stijn f31f9a8b70 py/objint: Do not use fpclassify. 5 years ago
Jim Mussared def76fe4d9 all: Use MP_ERROR_TEXT for all error messages. 5 years ago
Damien George 69661f3343 all: Reformat C and Python source code with tools/codeformat.py. 5 years ago
Damien George c13f9f209d all: Convert nlr_raise(mp_obj_new_exception_msg(x)) to mp_raise_msg(x). 5 years ago
Damien George eee1e8841a py: Downcase all MP_OBJ_IS_xxx macros to make a more consistent C API. 6 years ago
Paul Sokolovsky b1d08726ee py/obj: Add support for __int__ special method. 6 years ago
Damien George cc5c3c64ca py/objint: Remove TODO about checking of int() arg types with 2 args. 6 years ago
Damien George 9884a2c712 py/objint: Remove unreachable code checking for int type in format func. 7 years ago
Damien George fe3e17b026 py/objint: Use MP_OBJ_IS_STR_OR_BYTES macro instead of 2 separate ones. 7 years ago
Damien George a3dc1b1957 all: Remove inclusion of internal py header files. 7 years ago
Paul Sokolovsky 9dce823cfd py/modbuiltins: Implement abs() by dispatching to MP_UNARY_OP_ABS. 7 years ago
Damien George 58321dd985 all: Convert mp_uint_t to mp_unary_op_t/mp_binary_op_t where appropriate 7 years ago
Alexander Steffen 55f33240f3 all: Use the name MicroPython consistently in comments 7 years ago
Tom Collins 145796f037 py,extmod: Some casts and minor refactors to quiet compiler warnings. 7 years ago
Damien George e269cabe3e py/objint: In to_bytes(), allow length arg to be any int and check sign. 8 years ago
Damien George 8c5632a869 py/objint: Support "big" byte-order in int.to_bytes(). 8 years ago
Damien George 58bb73e010 py/objint: In int.from_bytes, only create big-int if really needed. 8 years ago
Damien George e31fbd9b41 py/objint: Use unsigned arithmetic when formatting an integer. 8 years ago
Damien George f66df1efc8 py/objint: Extract small int value directly because type is known. 8 years ago
Damien George fc245d1ca4 py/objint: Consolidate mp_obj_new_int_from_float to one implementation. 8 years ago
Damien George 6b34107537 py: Change mp_uint_t to size_t for mp_obj_str_get_data len arg. 8 years ago
Damien George c073519ec8 py/objint: Handle special case of -0 when classifying fp as int. 8 years ago
Damien George d1ae6ae080 py/objint: Allow to print long-long ints without using the heap. 8 years ago
Damien George da36f5232d py/objint: Convert mp_uint_t to size_t where appropriate. 8 years ago
Damien George eaa77455c3 py/objint: Fix left-shift overflow in checking for large int. 8 years ago
Paul Sokolovsky bec7bfb29d py/objint: from_bytes(): Implement "byteorder" param and arbitrary precision. 8 years ago
Damien George ea6a958393 py/objint: Simplify mp_int_format_size and remove unreachable code. 8 years ago
Damien George e4af712125 py/objint: Rename mp_obj_int_as_float to mp_obj_int_as_float_impl. 8 years ago
Paul Sokolovsky 9d787de2a1 py/objint: from_bytes, to_bytes: Require byteorder arg, require "little". 8 years ago
Damien George 7d0d7215d2 py: Use mp_raise_msg helper function where appropriate. 8 years ago
Damien George 6dff3df501 py/objint: Use size_t for arguments that measure bytes/sizes. 8 years ago
Damien George 8bb7d958f1 py: Factor duplicated function to calculate size of formatted int. 8 years ago
Damien George 9ae51257bd py: Use MP_SMALL_INT_POSITIVE_MASK to check if uint fits in a small int. 9 years ago
Damien George 5b3f0b7f39 py: Change first arg of type.make_new from mp_obj_t to mp_obj_type_t*. 9 years ago
Damien George 4b72b3a133 py: Change type signature of builtin funs that take variable or kw args. 9 years ago
Damien George a0c97814df py: Change type of .make_new and .call args: mp_uint_t becomes size_t. 9 years ago
Damien George da3dffa79d py/objint: Fix classification of float so it works for OBJ_REPR_D. 9 years ago
Damien George d6b31e4578 py: Change mp_obj_int_is_positive to more general mp_obj_int_sign. 9 years ago
Damien George 999cedb90f py: Wrap all obj-ptr conversions in MP_OBJ_TO_PTR/MP_OBJ_FROM_PTR. 9 years ago
Damien George cbf7674025 py: Add MP_ROM_* macros and mp_rom_* types and use them. 9 years ago
Damien George aaef1851a7 py: Add mp_obj_is_float function (macro) and use it where appropriate. 9 years ago