Return True if `node` holds a tuple that contains a star operator.
(node: LN)
| 652 | |
| 653 | |
| 654 | def is_tuple_containing_star(node: LN) -> bool: |
| 655 | """Return True if `node` holds a tuple that contains a star operator.""" |
| 656 | if node.type != syms.atom: |
| 657 | return False |
| 658 | gexp = unwrap_singleton_parenthesis(node) |
| 659 | if gexp is None or gexp.type != syms.testlist_gexp: |
| 660 | return False |
| 661 | |
| 662 | return any(child.type == syms.star_expr for child in gexp.children) |
| 663 | |
| 664 | |
| 665 | def is_generator(node: LN) -> bool: |
no test coverage detected