---
source: crates/ruff_linter/src/linter.rs
---
F706 `return` statement outside of a function/method
  --> resources/test/fixtures/syntax_errors/return_outside_function.py:13:1
   |
13 | return 1  # error
   | ^^^^^^^^
14 | return  # error
   |

F706 `return` statement outside of a function/method
  --> resources/test/fixtures/syntax_errors/return_outside_function.py:14:1
   |
13 | return 1  # error
14 | return  # error
   | ^^^^^^
   |

F706 `return` statement outside of a function/method
  --> resources/test/fixtures/syntax_errors/return_outside_function.py:18:5
   |
17 | class C:
18 |     return 1  # error
   |     ^^^^^^^^
   |

F706 `return` statement outside of a function/method
  --> resources/test/fixtures/syntax_errors/return_outside_function.py:23:9
   |
21 | def f():
22 |     class C:
23 |         return 1  # error
   |         ^^^^^^^^
   |
