weimingtom / tinypy

Automatically exported from code.google.com/p/tinypy
Other
1 stars 0 forks source link

cpython module needs unittests, examples, and docs. #35

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
The cpython module doesn't seem to have any unittests, examples or docs.

More information here:
http://groups.google.com/group/tinypy/browse_thread/thread/67908894bff0fba9

Original issue reported on code.google.com by ren...@gmail.com on 23 Sep 2008 at 7:09

GoogleCodeExporter commented 9 years ago
I've been writing some, will post what I have in the next couple of days.

Or see above link for file to add your own tests to.

Original comment by ren...@gmail.com on 24 Sep 2008 at 12:49

GoogleCodeExporter commented 9 years ago
hi,

Here's some updates...

http://rene.f0o.com/~rene/cpython.c
http://rene.f0o.com/~rene/cpython_tests.py

Fixes the re-raising of exceptions.  It was tinypy code fault, not the cpython 
codes
fault.  So someone who knows tinpy better should have a look.

It runs all the tests from tinypy inside a cpython unittest, plus some other 
tests.

There was an issue with setjmp on mingw as well.  Haven't tested on other
platforms... but it *should* be ok... I think.

Note, that setjmp/longjmp should be made into tp_setjmp/tp_longjmp.  Because 
you need
to use different functions on different platforms... like sigsetjmp if using 
posix
signals(like in cpython).

The threading is disabled... because the macros can't be used... need to do that
stuff manually to work with the setjmp.

Needs more documentation...  and think about how multiple execute calls 
work(reset
time/memory limits or not?).

cheers,

Original comment by ren...@gmail.com on 24 Sep 2008 at 12:50