FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Adding generator_stop to compile_future_features by matheusfgoncalves95 · Pull Request #5320 · RustPython/RustPython · GitHub

Adding generator_stop to compile_future_features - #5320

Merged
youknowone merged 3 commits into
RustPython:mainfrom
matheusfgoncalves95:generator-stop
May 13, 2024
Merged

Adding generator_stop to compile_future_features#5320
youknowone merged 3 commits into
RustPython:mainfrom
matheusfgoncalves95:generator-stop

Conversation

matheusfgoncalves95 commented May 13, 2024
edited by youknowone
Loading

Copy link
Copy Markdown
Contributor

As well as some mild formatting.

Fix #4060

Comment thread compiler/codegen/src/compile.rs Outdated
Comment on lines +2913 to +2914
| "compile_future_features" => {}
"generator_stop" => {}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Does this work?

Suggested change
| "compile_future_features" => {}
"generator_stop" => {}
| "compile_future_features"
| "generator_stop" => {}

matheusfgoncalves95 May 13, 2024
edited
Loading

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Oops, my autoformatter led to that silly mistake. I also somehow introduced compile_future_features there!

To answer your question: it seems to work.

I did a quick check on the Python interpreter and the import succeeds. The module also looks okay via dir() inspection.

Anyhow, I will fix it. Thanks for pointing that out.

youknowone left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Thank you for contributing! Your patch also fixed a test in test_contextlib. Could you also update the test? Removing @unittest.expectedFailure will fix the CI failure

youknowone merged commit 515f0bf into RustPython:main May 13, 2024
matheusfgoncalves95 deleted the generator-stop branch May 13, 2024 21:52
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
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.

allow from __future__ import generator_stop

3 participants


Back | FazBrowse Home | New Git URL