Skip to content

Commit

Permalink
Added comparison-with-itself message example (#6157)
Browse files Browse the repository at this point in the history
Co-authored-by: Vladyslav Krylasov <[email protected]>
Co-authored-by: Pierre Sassoulas <[email protected]>
  • Loading branch information
3 people authored Apr 3, 2022
1 parent a36f152 commit f468b5d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
3 changes: 3 additions & 0 deletions doc/data/messages/c/comparison-with-itself/bad.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
def is_an_orange(fruit):
an_orange = "orange"
return fruit == fruit # [comparison-with-itself]
3 changes: 3 additions & 0 deletions doc/data/messages/c/comparison-with-itself/good.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
def is_an_orange(fruit):
an_orange = "orange"
return an_orange == fruit

0 comments on commit f468b5d

Please sign in to comment.