summaryrefslogtreecommitdiffstatshomepage
path: root/py/qstrdefs.h
Commit message (Collapse)AuthorAge
* py: Make print() accept "file" argument, and actually print to stream.Paul Sokolovsky2014-07-19
| | | | | And not system printf(), like it was before. For this, move pfenv_printf() from stmhal port to py/.
* moductypes: Add symbolic constants to specify bitfield position/length.Paul Sokolovsky2014-07-11
|
* moductypes: Foreign data interface module, roughly based on ctype ideas.Paul Sokolovsky2014-07-09
| | | | | But much smaller and memory-efficient. Uses Python builtin data structures (dict, tuple, int) to describe structure layout.
* py: Implement sys.maxsize, standard way to check platform "bitness".Paul Sokolovsky2014-07-03
| | | | | Implementing it as a static constant is a bit peculiar and require cooperation from long int implementation.
* modgc: Add mem_free()/mem_alloc() methods.Paul Sokolovsky2014-06-25
| | | | Return free/allocated memory on GC heap.
* py: Rename builtin "io" to "_io".Paul Sokolovsky2014-06-12
| | | | | | | | Functionality we provide in builtin io module is fairly minimal. Some code, including CPython stdlib, depends on more functionality. So, there's a choice to either implement it in C, or move it _io, and let implement other functionality in Python. 2nd choice is pursued. This setup matches CPython too (_io is builtin, io is Python-level).
* objtype: Enable __lt__ method support for instances.Paul Sokolovsky2014-06-08
|
* modsys: Add optional support for sys.platform.Paul Sokolovsky2014-06-07
| | | | | Ports which wants to have it, should define MICROPY_PY_SYS_PLATFORM to a string value they need.
* Rename bultins config variables to MICROPY_PY_BUILTINS_*.Damien George2014-06-01
| | | | | | | | | | This renames: MICROPY_PY_FROZENSET -> MICROPY_PY_BUILTINS_FROZENSET MICROPY_PY_PROPERTY -> MICROPY_PY_BUILTINS_PROPERTY MICROPY_PY_SLICE -> MICROPY_PY_BUILTINS_SLICE MICROPY_ENABLE_FLOAT -> MICROPY_PY_BUILTINS_FLOAT See issue #35 for discussion.
* add methods isspace(), isalpha(), isdigit(), isupper() and islower() to strKim Bauters2014-05-31
|
* Add SystemExit exception and use it in unix/ and stmhal/ ports.Damien George2014-05-24
| | | | Addresses issue #598.
* Rename configuration variables controling Python features.Damien George2014-05-24
| | | | Now of the form MICROPY_PY_*. See issue #35.
* objstr: Implement .endswith().Paul Sokolovsky2014-05-24
|
* py: Implement proper separation between io.FileIO and io.TextIOWrapper.Paul Sokolovsky2014-05-19
| | | | | | | io.FileIO is binary I/O, ans actually optional. Default file type is io.TextIOWrapper, which provides str results. CPython3 explicitly describes io.TextIOWrapper as buffered I/O, but we don't have buffering support yet anyway.
* objtype: Separate __new__ and __init__ methods.Paul Sokolovsky2014-05-19
| | | | | | | | | | | Now schedule is: for native types, we call ->make_new() C-level method, which should perform actions of __new__ and __init__ (note that this is not compliant, but is efficient), but for user types, __new__ and __init__ are called as expected. Also, make sure we convert scalar attribute value to a bound-pair tight in mp_obj_class_lookup() method, which avoids converting it again and again in its callers.
* objstr.c: Partial implementation of .rsplit().Paul Sokolovsky2014-05-14
| | | | sep=None is TODO.
* py: Add basic implementation of hasattr() function.Paul Sokolovsky2014-05-11
|
* objstr: Implement .lower() and .upper().Paul Sokolovsky2014-05-10
|
* modsys, unix: Add sys.exit(), should be implemented by a port.Paul Sokolovsky2014-05-10
|
* objset: Give up and implement frozenset.Paul Sokolovsky2014-05-10
| | | | Tired of patching CPython stdlib for it.
* py: Rename byte_code to bytecode everywhere.Damien George2014-05-10
| | | | bytecode is the more widely used. See issue #590.
* Add gc.enable, gc.disable; remove pyb.gc.Damien George2014-05-08
|
* py, compiler: Add basic support for A=const(123).Damien George2014-05-08
| | | | | | | | | | | You can now do: X = const(123) Y = const(456 + X) and the compiler will replace X and Y with their values. See discussion in issue #266 and issue #573.
* py: Add keyword arg support to enumerate constructor.Damien George2014-05-06
| | | | | | | | Need to have a policy as to how far we go adding keyword support to built ins. It's nice to have, and gets better CPython compatibility, but hurts the micro nature of uPy. Addresses issue #577.
* modgc: Add new module for GC-related functionality.Paul Sokolovsky2014-05-06
|
* Add license header to (almost) all files.Damien George2014-05-03
| | | | | | | 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/.
* py, stream: Implement readlines for a stream.Damien George2014-05-03
|
* py: Remove silly comment about interning keywords.Damien George2014-04-28
| | | | | | | | | | Of course, keywords are turned into lexer tokens in the lexer, so will never need to be interned (unless you do something like x="def"). As it is now, the following on pyboard makes no new qstrs: import pyb pyb.info()
* py: Add '*' qstr for 'import *'; use blank qstr for comprehension arg.Damien George2014-04-27
|
* py: "read" & "write" are so common that make them core.Paul Sokolovsky2014-04-26
| | | | Few other strings move to core, but make depend on "io" module.
* modio: Implement io.StringIO class.Paul Sokolovsky2014-04-26
|
* objstr: Implement .lstrip() & .rstrip().Paul Sokolovsky2014-04-26
| | | | Share code with .strip(). TODO: optimize .rstrip().
* py: Support instance __call__ method.Paul Sokolovsky2014-04-25
|
* py: Add 'align' and 'data' meta-instructions to inline assembler.Damien George2014-04-21
|
* modstruct: Initial implementation of struct.pack().Paul Sokolovsky2014-04-19
|
* py: Add cmath module, for complex math. Disabled by default.Damien George2014-04-17
| | | | Not all functions implemented. Not enabled on pyboard.
* py: Add builtin functions bin and oct, and some tests for them.Damien George2014-04-15
|
* py: Fix builtin hex to print prefix.Damien George2014-04-15
| | | | I was too hasty. Still a one-liner though.
* py: Add hex builtin function.Damien George2014-04-15
| | | | A one-liner, added especially for @pfalcon :)
* modsys: Implement sys.version.Paul Sokolovsky2014-04-14
| | | | | | | | The logic appears to be that (at least beginning of) sys.versions is the version of reference Python language implemented, not version of particular implementation. Also, bump set versions at 3.4.0, based on @dpgeorge preference.
* objdict: Add __delitem__.Paul Sokolovsky2014-04-13
|
* py: Add property object, with basic functionality.Damien George2014-04-13
| | | | Enabled by MICROPY_ENABLE_PROPERTY.
* modsys: Implement sys.byteorder.Paul Sokolovsky2014-04-13
|
* modsys: Implement basic sys.version_info.Paul Sokolovsky2014-04-13
|
* Merge pull request #476 from pfalcon/static-sysDamien George2014-04-13
|\ | | | | Convert sys module to static allocation
| * py: Move sys attribute qstrs's to core.Paul Sokolovsky2014-04-13
| |
* | objset: Implement __contains__() op-method.Paul Sokolovsky2014-04-13
| |
* | py: Rename collections module to _collections.Paul Sokolovsky2014-04-13
|/ | | | | We're not going to implement all the plethora of types in there in C. Funnily, CPython implements defaultdict in C, and namedtuple in Python.
* objstr: Add str.encode() and bytes.decode() methods.Paul Sokolovsky2014-04-13
| | | | | These largely duplicate str() & bytes() constructors' functionality, but can be used to achieve Python2 compatibility.
* builtinimport: Set __path__ attribute on packages.Paul Sokolovsky2014-04-12
| | | | | | | Per https://docs.python.org/3.3/reference/import.html , this is the way to tell module from package: "Specifically, any module that contains a __path__ attribute is considered a package." And it for sure will be needed to implement relative imports.