Skip to content
Snippets Groups Projects
  1. Dec 17, 2015
  2. Nov 29, 2015
    • Damien George's avatar
      py: Wrap all obj-ptr conversions in MP_OBJ_TO_PTR/MP_OBJ_FROM_PTR. · 999cedb9
      Damien George authored
      This allows the mp_obj_t type to be configured to something other than a
      pointer-sized primitive type.
      
      This patch also includes additional changes to allow the code to compile
      when sizeof(mp_uint_t) != sizeof(void*), such as using size_t instead of
      mp_uint_t, and various casts.
      999cedb9
  3. Oct 01, 2015
  4. Feb 13, 2015
  5. Feb 08, 2015
    • Damien George's avatar
      py: Parse big-int/float/imag constants directly in parser. · 7d414a1b
      Damien George authored
      Previous to this patch, a big-int, float or imag constant was interned
      (made into a qstr) and then parsed at runtime to create an object each
      time it was needed.  This is wasteful in RAM and not efficient.  Now,
      these constants are parsed straight away in the parser and turned into
      objects.  This allows constants with large numbers of digits (so
      addresses issue #1103) and takes us a step closer to #722.
      7d414a1b
  6. Feb 07, 2015
    • Damien George's avatar
      py: Protect mp_parse and mp_compile with nlr push/pop block. · 0bfc7638
      Damien George authored
      To enable parsing constants more efficiently, mp_parse should be allowed
      to raise an exception, and mp_compile can already raise a MemoryError.
      So these functions need to be protected by an nlr push/pop block.
      
      This patch adds that feature in all places.  This allows to simplify how
      mp_parse and mp_compile are called: they now raise an exception if they
      have an error and so explicit checking is not needed anymore.
      0bfc7638
  7. Jan 01, 2015
  8. Dec 27, 2014
  9. Oct 03, 2014
  10. Jul 03, 2014
  11. May 28, 2014
  12. May 25, 2014
    • Damien George's avatar
      py: Don't automatically intern strings in parser. · 5042bce8
      Damien George authored
      This completes non-automatic interning of strings in the parser, so that
      doc strings don't take up RAM.  It complicates the parser and compiler,
      and bloats stmhal by about 300 bytes.  It's complicated because now
      there are 2 kinds of parse-nodes that can be strings: interned leaves
      and non-interned structs.
      5042bce8
  13. May 08, 2014
  14. May 03, 2014
    • Damien George's avatar
      Add license header to (almost) all files. · 04b9147e
      Damien George authored
      Blanket wide to all .c and .h files.  Some files originating from ST are
      difficult to deal with (license wise) so it was left out of those.
      
      Also merged modpyb.h, modos.h, modstm.h and modtime.h in stmhal/.
      04b9147e
  15. Apr 10, 2014
  16. Feb 22, 2014
  17. Feb 21, 2014
  18. Feb 15, 2014
    • Damien George's avatar
      Implement proper exception type hierarchy. · c5966128
      Damien George authored
      Each built-in exception is now a type, with base type BaseException.
      C exceptions are created by passing a pointer to the exception type to
      make an instance of.  When raising an exception from the VM, an
      instance is created automatically if an exception type is raised (as
      opposed to an exception instance).
      
      Exception matching (RT_BINARY_OP_EXCEPTION_MATCH) is now proper.
      
      Handling of parse error changed to match new exceptions.
      
      mp_const_type renamed to mp_type_type for consistency.
      c5966128
  19. Jan 25, 2014
  20. Jan 19, 2014
  21. Jan 18, 2014
  22. Jan 15, 2014
  23. Dec 21, 2013
    • Damien's avatar
      Change object representation from 1 big union to individual structs. · d99b0528
      Damien authored
      A big change.  Micro Python objects are allocated as individual structs
      with the first element being a pointer to the type information (which
      is itself an object).  This scheme follows CPython.  Much more flexible,
      not necessarily slower, uses same heap memory, and can allocate objects
      statically.
      
      Also change name prefix, from py_ to mp_ (mp for Micro Python).
      d99b0528
  24. Oct 18, 2013
  25. Oct 12, 2013
  26. Oct 04, 2013
Loading