Add a BindingKind for WithItem variables (#8594)

This commit is contained in:
Charlie Marsh
2023-11-09 19:44:49 -08:00
committed by GitHub
parent 0ac124acef
commit 346a828db2
5 changed files with 19 additions and 1 deletions

View File

@@ -432,6 +432,13 @@ pub enum BindingKind<'a> {
/// ```
LoopVar,
/// A binding for a with statement variable, like `x` in:
/// ```python
/// with open('foo.py') as x:
/// ...
/// ```
WithItemVar,
/// A binding for a global variable, like `x` in:
/// ```python
/// def foo():