Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add "doctest" support #807

Merged
merged 5 commits into from
Aug 6, 2015
Merged

Add "doctest" support #807

merged 5 commits into from
Aug 6, 2015

Conversation

kmod
Copy link
Collaborator

@kmod kmod commented Aug 6, 2015

Needed tuple.__module__ and sys.displayhook support.

A number of cpython's tests use doctest, so getting this to work meant some of those now pass and others get farther. test_doctest is unfortunately not working, but since they use doctest to test itself... it's hard to tell whether it's the testing or tested part that's failing (or both). If anyone is interested feel free to take a look :)

kmod added 5 commits August 6, 2015 10:05
This was stemming from our use of the HEAPTYPE flag for our builtins,
and cpython inferring "is builtin" from that.

Also, fix a couple other minor things that I ran into.
ie what you create either on the repl (where we were close) or
with `exec compile(foo, bar, "single")` (where we were not so close).

With these changes, doctest seems to mostly be working.
My guess is that there's a build dependency issue, where
we try building files that include libunwind.h before we
run the rules that generate it.  Not sure why we weren't running
into that before.  But the normal c++ files in src/ correctly
depend on libunwind, but the ones in src/runtime/inline don't
seem to.

For good measure, don't include libunwind.h in our header files,
and just use forward-declaring.
kmod added a commit that referenced this pull request Aug 6, 2015
@kmod kmod merged commit 3d8398b into pyston:master Aug 6, 2015
@kmod kmod deleted the doctest branch August 8, 2015 00:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant