Skip to content

Commit

Permalink
More precise types in preserve_defaults.py (#12385)
Browse files Browse the repository at this point in the history
  • Loading branch information
JelleZijlstra committed May 18, 2024
1 parent a51331c commit 6ce4f96
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sphinx/ext/autodoc/preserve_defaults.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ def _get_arguments_inner(x: Any, /) -> ast.arguments | None:
return None


def get_default_value(lines: list[str], position: ast.AST) -> str | None:
def get_default_value(lines: list[str], position: ast.expr) -> str | None:
try:
if position.lineno == position.end_lineno:
line = lines[position.lineno - 1]
Expand Down

0 comments on commit 6ce4f96

Please sign in to comment.