ruff/crates/ruff_python_ast/tests/snapshots
Charlie Marsh adc8bb7821
Rename Arguments to Parameters in the AST (#6253)
## Summary

This PR renames a few AST nodes for clarity:

- `Arguments` is now `Parameters`
- `Arg` is now `Parameter`
- `ArgWithDefault` is now `ParameterWithDefault`

For now, the attribute names that reference `Parameters` directly are
changed (e.g., on `StmtFunctionDef`), but the attributes on `Parameters`
itself are not (e.g., `vararg`). We may revisit that decision in the
future.

For context, the AST node formerly known as `Arguments` is used in
function definitions. Formally (outside of the Python context),
"arguments" typically refers to "the values passed to a function", while
"parameters" typically refers to "the variables used in a function
definition". E.g., if you Google "arguments vs parameters", you'll get
some explanation like:

> A parameter is a variable in a function definition. It is a
placeholder and hence does not have a concrete value. An argument is a
value passed during function invocation.

We're thus deviating from Python's nomenclature in favor of a scheme
that we find to be more precise.
2023-08-01 13:53:28 -04:00
..
preorder__class_type_parameters.snap Pull in RustPython parser (#6099) 2023-07-27 09:29:11 +00:00
preorder__compare.snap Pull in RustPython parser (#6099) 2023-07-27 09:29:11 +00:00
preorder__decorators.snap Rename Arguments to Parameters in the AST (#6253) 2023-08-01 13:53:28 -04:00
preorder__dict_comprehension.snap Pull in RustPython parser (#6099) 2023-07-27 09:29:11 +00:00
preorder__function_arguments.snap Rename Arguments to Parameters in the AST (#6253) 2023-08-01 13:53:28 -04:00
preorder__function_positional_only_with_default.snap Rename Arguments to Parameters in the AST (#6253) 2023-08-01 13:53:28 -04:00
preorder__function_type_parameters.snap Rename Arguments to Parameters in the AST (#6253) 2023-08-01 13:53:28 -04:00
preorder__list_comprehension.snap Pull in RustPython parser (#6099) 2023-07-27 09:29:11 +00:00
preorder__match_class_pattern.snap Pull in RustPython parser (#6099) 2023-07-27 09:29:11 +00:00
preorder__set_comprehension.snap Pull in RustPython parser (#6099) 2023-07-27 09:29:11 +00:00
preorder__type_aliases.snap Pull in RustPython parser (#6099) 2023-07-27 09:29:11 +00:00
visitor__class_type_parameters.snap Pull in RustPython parser (#6099) 2023-07-27 09:29:11 +00:00
visitor__compare.snap Pull in RustPython parser (#6099) 2023-07-27 09:29:11 +00:00
visitor__decorators.snap Rename Arguments to Parameters in the AST (#6253) 2023-08-01 13:53:28 -04:00
visitor__dict_comprehension.snap Pull in RustPython parser (#6099) 2023-07-27 09:29:11 +00:00
visitor__function_arguments.snap Rename Arguments to Parameters in the AST (#6253) 2023-08-01 13:53:28 -04:00
visitor__function_positional_only_with_default.snap Rename Arguments to Parameters in the AST (#6253) 2023-08-01 13:53:28 -04:00
visitor__function_type_parameters.snap Rename Arguments to Parameters in the AST (#6253) 2023-08-01 13:53:28 -04:00
visitor__list_comprehension.snap Pull in RustPython parser (#6099) 2023-07-27 09:29:11 +00:00
visitor__match_class_pattern.snap Pull in RustPython parser (#6099) 2023-07-27 09:29:11 +00:00
visitor__set_comprehension.snap Pull in RustPython parser (#6099) 2023-07-27 09:29:11 +00:00
visitor__type_aliases.snap Pull in RustPython parser (#6099) 2023-07-27 09:29:11 +00:00