mirror of
https://github.com/RustPython/RustPython.git
synced 2026-10-28 18:59:04 +08:00
Adding generator_stop to compile_future_features (#5320)
* Adding generator_stop to compile_future_features. * Removing expected failure from PEP 479 unit test.
This commit is contained in:
1 parent
27a52a7962
commit
515f0bf9c2
2 files changed
+1
-4
No files matched your search
Vendored
-2
@@ -197,8 +197,6 @@ class ContextManagerTestCase(unittest.TestCase):
|
||||
else:
|
||||
self.fail(f'{stop_exc} was suppressed')
|
||||
|
||||
# TODO: RUSTPYTHON
|
||||
@unittest.expectedFailure
|
||||
def test_contextmanager_except_pep479(self):
|
||||
code = """\
|
||||
from __future__ import generator_stop
|
||||
|
||||
@@ -2904,8 +2904,7 @@ impl Compiler {
|
||||
match feature.name.as_str() {
|
||||
// Python 3 features; we've already implemented them by default
|
||||
"nested_scopes" | "generators" | "division" | "absolute_import"
|
||||
| "with_statement" | "print_function" | "unicode_literals" => {}
|
||||
// "generator_stop" => {}
|
||||
| "with_statement" | "print_function" | "unicode_literals" | "generator_stop" => {}
|
||||
"annotations" => self.future_annotations = true,
|
||||
other => {
|
||||
return Err(self.error(CodegenErrorType::InvalidFutureFeature(other.to_owned())))
|
||||
|
||||
Reference in new issue
Block a user