<feed xmlns='http://www.w3.org/2005/Atom'>
<title>suspect-devices/circuitpython/py/obj.h, branch v1.3.6</title>
<subtitle>CircuitPython - a Python implementation for teaching coding with microcontrollers</subtitle>
<id>https://git.suspectdevices.com/suspect-devices/circuitpython/atom?h=v1.3.6</id>
<link rel='self' href='https://git.suspectdevices.com/suspect-devices/circuitpython/atom?h=v1.3.6'/>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/'/>
<updated>2014-10-25T22:37:57+00:00</updated>
<entry>
<title>py: Add mp_pending_exception global variable, for VM soft interrupt.</title>
<updated>2014-10-25T22:37:57+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-10-25T17:19:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=124df6f8d07b53542b6960dbeea9b63bff469a67'/>
<id>urn:sha1:124df6f8d07b53542b6960dbeea9b63bff469a67</id>
<content type='text'>
This allows to implement KeyboardInterrupt on unix, and a much safer
ctrl-C in stmhal port.  First ctrl-C is a soft one, with hope that VM
will notice it; second ctrl-C is a hard one that kills anything (for
both unix and stmhal).

One needs to check for a pending exception in the VM only for jump
opcodes.  Others can't produce an infinite loop (infinite recursion is
caught by stack check).
</content>
</entry>
<entry>
<title>py: Factor out mp_obj_is_package() function.</title>
<updated>2014-10-25T19:31:33+00:00</updated>
<author>
<name>Paul Sokolovsky</name>
<email>pfalcon@users.sourceforge.net</email>
</author>
<published>2014-10-25T18:04:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=e5a3759ff5478392f914ba7a7346da60d9735bf4'/>
<id>urn:sha1:e5a3759ff5478392f914ba7a7346da60d9735bf4</id>
<content type='text'>
</content>
</entry>
<entry>
<title>py: Store bytecode arg names in bytecode (were in own array).</title>
<updated>2014-10-25T19:23:13+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-10-25T14:07:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=1084b0f9c21b093618da4494508dec9ca8467e35'/>
<id>urn:sha1:1084b0f9c21b093618da4494508dec9ca8467e35</id>
<content type='text'>
This saves a lot of RAM for 2 reasons:

1. For functions that don't have default values, var args or var kw
args (which is a large number of functions in the general case), the
mp_obj_fun_bc_t type now fits in 1 GC block (previously needed 2 because
of the extra pointer to point to the arg_names array).  So this saves 16
bytes per function (32 bytes on 64-bit machines).

2. Combining separate memory regions generally saves RAM because the
unused bytes at the end of the GC block are saved for 1 of the blocks
(since that block doesn't exist on its own anymore).  So generally this
saves 8 bytes per function.

Tested by importing lots of modules:

- 64-bit Linux gave about an 8% RAM saving for 86k of used RAM.
- pyboard gave about a 6% RAM saving for 31k of used RAM.
</content>
</entry>
<entry>
<title>py: Add builtin memoryview object (mostly using array code).</title>
<updated>2014-10-23T12:34:35+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-10-23T12:34:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=dd4f4530ab35c162252b003d2713b06eb65903e1'/>
<id>urn:sha1:dd4f4530ab35c162252b003d2713b06eb65903e1</id>
<content type='text'>
</content>
</entry>
<entry>
<title>py: Remove unused and unneeded SystemError exception.</title>
<updated>2014-10-22T18:42:55+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-10-22T18:42:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=e7a478204a984f9f79a99700375d961be6d28a96'/>
<id>urn:sha1:e7a478204a984f9f79a99700375d961be6d28a96</id>
<content type='text'>
It's purpose is for internal errors that are not catastrophic (ie not as
bad as RuntimeError).  Since we don't use it, we don't need it.
</content>
</entry>
<entry>
<title>py: Make mp_const_empty_bytes globally available.</title>
<updated>2014-10-21T20:02:56+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-10-11T16:56:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=20f59e182e1ca5874a94ce939f8a81af6c3dd71a'/>
<id>urn:sha1:20f59e182e1ca5874a94ce939f8a81af6c3dd71a</id>
<content type='text'>
</content>
</entry>
<entry>
<title>py: Convert [u]int to mp_[u]int_t where appropriate.</title>
<updated>2014-10-03T17:44:14+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-10-03T17:44:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=42f3de924bc3e285490f5f293955bc6d7e5a0edf'/>
<id>urn:sha1:42f3de924bc3e285490f5f293955bc6d7e5a0edf</id>
<content type='text'>
Addressing issue #50.
</content>
</entry>
<entry>
<title>py: Remove IOError since it's deprecated; use OSError instead.</title>
<updated>2014-09-30T13:59:30+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-09-30T13:59:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=8b03d944e2ae64f7987116ff342fbd1cc3b97b71'/>
<id>urn:sha1:8b03d944e2ae64f7987116ff342fbd1cc3b97b71</id>
<content type='text'>
In CPython IOError (and EnvironmentError) is deprecated and aliased to
OSError.  All modules that used to raise IOError now raise OSError (or a
derived exception).

In Micro Python we never used IOError (except 1 place, incorrectly) and
so don't need to keep it.

See http://legacy.python.org/dev/peps/pep-3151/ for background.
</content>
</entry>
<entry>
<title>py: Tidy up exception matching; allow matching of tuple of exceptions.</title>
<updated>2014-09-25T14:49:26+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-09-24T13:05:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=4bcd04bcaddeeb53779f2c067a4d1b533c888f9d'/>
<id>urn:sha1:4bcd04bcaddeeb53779f2c067a4d1b533c888f9d</id>
<content type='text'>
Addresses issue #864.
</content>
</entry>
<entry>
<title>py: Add native json printing using existing print framework.</title>
<updated>2014-09-17T21:56:34+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-09-17T21:56:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=612045f53f7e5edf9faa359ee9ee52d490d58000'/>
<id>urn:sha1:612045f53f7e5edf9faa359ee9ee52d490d58000</id>
<content type='text'>
Also add start of ujson module with dumps implemented.  Enabled in unix
and stmhal ports.  Test passes on both.
</content>
</entry>
</feed>
