Skip to content

Commit e5e3d99

Browse files
authored
[flake8-annotations] Make ANN401 example error out-of-the-box (#18974)
1 parent 85b2a08 commit e5e3d99

File tree

1 file changed

+6
-0
lines changed
  • crates/ruff_linter/src/rules/flake8_annotations/rules

1 file changed

+6
-0
lines changed

crates/ruff_linter/src/rules/flake8_annotations/rules/definition.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -476,12 +476,18 @@ impl Violation for MissingReturnTypeClassMethod {
476476
/// ## Example
477477
///
478478
/// ```python
479+
/// from typing import Any
480+
///
481+
///
479482
/// def foo(x: Any): ...
480483
/// ```
481484
///
482485
/// Use instead:
483486
///
484487
/// ```python
488+
/// from typing import Any
489+
///
490+
///
485491
/// def foo(x: int): ...
486492
/// ```
487493
///

0 commit comments

Comments
 (0)