## Feature <!-- What Python feature is missing from RustPython? Give a short description of the feature and how you ran into its absence. --> In CPython, they can delete a list in following manner ```python3 >>> x = 1 >>> del [x] ``` But, in RustPython we cannot. ```python3 >>> del [x] SyntaxError: cannot delete list at line 1 column 1 del [x] ^ ``` Related test is in `Lib/test/test_syntax.py`. ```python3 def test_assign_del(self): # ... self._check_error("del [*x,]", "cannot delete starred") # Not "cannot delete list" ``` ## Python Documentation <!-- Give a link to the feature in the CPython documentation (https://docs.python.org/3/) in order to assist in its implementation. --> Cannot find documentation exactly related this difference.
Activity
[-]cannot delete 'list'[/-][+]cannot delete list `del [x]`[/+]key262yek commentedon Jul 14, 2022
related to #3879
[-]cannot delete list `del [x]`[/-][+]cannot delete list directly `del [x]`[/+]key262yek commentedon Jul 14, 2022
I add match to List in compile_delete() in file compile/src/compile.rs
pr #3879 includes the code changes.
key262yek commentedon Jul 20, 2022
It is resolved by pr #3879