mirror of
https://github.com/RustPython/Parser.git
synced 2025-07-15 09:05:25 +00:00
Parse FormattedValue spec in symboltable
This commit is contained in:
parent
de7f9efd54
commit
3827dbfc49
1 changed files with 8 additions and 1 deletions
|
@ -726,8 +726,15 @@ impl SymbolTableBuilder {
|
||||||
fn scan_string_group(&mut self, group: &ast::StringGroup) -> SymbolTableResult {
|
fn scan_string_group(&mut self, group: &ast::StringGroup) -> SymbolTableResult {
|
||||||
match group {
|
match group {
|
||||||
ast::StringGroup::Constant { .. } => {}
|
ast::StringGroup::Constant { .. } => {}
|
||||||
ast::StringGroup::FormattedValue { value, .. } => {
|
ast::StringGroup::FormattedValue {
|
||||||
|
value,
|
||||||
|
conversion: _,
|
||||||
|
spec,
|
||||||
|
} => {
|
||||||
self.scan_expression(value, &ExpressionContext::Load)?;
|
self.scan_expression(value, &ExpressionContext::Load)?;
|
||||||
|
if let Some(spec) = spec {
|
||||||
|
self.scan_string_group(spec)?;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
ast::StringGroup::Joined { values } => {
|
ast::StringGroup::Joined { values } => {
|
||||||
for subgroup in values {
|
for subgroup in values {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue