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

connect to skulpt #50

Open
albertjan opened this issue Jun 24, 2021 · 1 comment
Open

connect to skulpt #50

albertjan opened this issue Jun 24, 2021 · 1 comment

Comments

@albertjan
Copy link
Member

postpone making python types till in compiler

intermediate types can toString to the exact cpython value, while maintaining metadata to construct skulpt types.

drawbacks:

  • our ast differs from cpythons because well use javascript types (with maybe annotation) we would need extra information to construct the right python type.

benefit:

  • not tied to skulpts implementation
@s-cork
Copy link
Contributor

s-cork commented Aug 2, 2021

Adding another idea.
Another way we could integrate with skulpt might be to pass a space object as an argument to the parser
(I think this is what pypy does)

space would need to implement pyStr, pySyntaxError, pyAdd essentially everything inside the mock_types folder and internally we just use our mock_types.

An advantange here is that we don't need to double up on methods in production code. And we also don't need to rely on the window.Sk object being defined globally.

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

No branches or pull requests

2 participants