mirror of
https://github.com/astral-sh/ruff.git
synced 2025-08-02 18:02:23 +00:00
docs(SIM114): fix typo in example Python code (#2884)
This commit is contained in:
parent
4dd2032687
commit
b8483975a4
1 changed files with 3 additions and 3 deletions
|
@ -118,15 +118,15 @@ define_violation!(
|
||||||
///
|
///
|
||||||
/// ### Example
|
/// ### Example
|
||||||
/// ```python
|
/// ```python
|
||||||
/// if x = 1:
|
/// if x == 1:
|
||||||
/// print("Hello")
|
/// print("Hello")
|
||||||
/// elif x = 2:
|
/// elif x == 2:
|
||||||
/// print("Hello")
|
/// print("Hello")
|
||||||
/// ```
|
/// ```
|
||||||
///
|
///
|
||||||
/// Use instead:
|
/// Use instead:
|
||||||
/// ```python
|
/// ```python
|
||||||
/// if x = 1 or x = 2:
|
/// if x == 1 or x == 2:
|
||||||
/// print("Hello")
|
/// print("Hello")
|
||||||
/// ```
|
/// ```
|
||||||
pub struct IfWithSameArms;
|
pub struct IfWithSameArms;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue