summaryrefslogtreecommitdiff
path: root/doc/data/messages/c/comparison-with-callable/bad.py
blob: 9dc5ecd9213ac6b8cdd7c80d0096a86e553fd157 (plain)
1
2
3
4
5
6
def function_returning_a_fruit() -> str:
    return "orange"

def is_an_orange(fruit: str = "apple"):
    # apple == <function function_returning_a_fruit at 0x7f343ff0a1f0>
    return fruit == function_returning_a_fruit  # [comparison-with-callable]