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

JSArrayProxy_iter and JSObjectProxy_iter should not create copies: implement true iterator types #211

Closed
philippedistributive opened this issue Jan 15, 2024 · 0 comments · Fixed by #215
Assignees

Comments

@philippedistributive
Copy link
Collaborator

philippedistributive commented Jan 15, 2024

Issue type

Bug

How did you install PythonMonkey?

None

OS platform and distribution

No response

Python version (python --version)

No response

PythonMonkey version (pip show pythonmonkey)

No response

Bug Description

implement subtype of PyListIter_Type so that no copying is required as it is now

Standalone code to reproduce the issue

import pythonmonkey as pm
a = pm.eval("[1,2]")
for i in a:
    print(i)

as well as

obj = pm.eval("({ a: 123, b: 'test' })")
result = []
for i in obj:
result.append(i)

Relevant log output or backtrace

No response

Additional info if applicable

No response

What branch of PythonMonkey were you developing on? (If applicable)

No response

@philippedistributive philippedistributive self-assigned this Jan 15, 2024
@philippedistributive philippedistributive changed the title JSArrayProxy_iter and JSObjectProxy_iter should not create copies: implement true iterator types JSArrayProxy_iter should not create copies: implement true iterator types Jan 16, 2024
@philippedistributive philippedistributive changed the title JSArrayProxy_iter should not create copies: implement true iterator types JSArrayProxy_iter and JSObjectProxy_iter should not create copies: implement true iterator types Jan 18, 2024
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 a pull request may close this issue.

1 participant