PyDocs

Nav

Python Language Services

Subscript

ast

class
  • Subscript(value, slice, ctx)
Subscript(expr value, expr slice, expr_context ctx)
1 Example
>>> print(ast.dump(ast.parse('l[1:2, 3]', mode='eval'), indent=4))
Expression(
    body=Subscript(
        value=Name(id='l'),
        slice=Tuple(
            elts=[
                Slice(
                    lower=Constant(value=1),
                    upper=Constant(value=2)),
                Constant(value=3)])))
from the Python docs
See Also
No see-alsos for ast/Subscript
0 Notes
No notes for Subscript