Languages
Post #3714 · source on Telegram
The Honest Pass Statement
Description
The image is a cropped documentation screenshot with the heading "4.5. pass Statements" and a single sentence underneath: "The pass statement does nothing." The word "pass" is styled like inline code in a monospace font, while the rest of the text appears in a clean documentation layout. The humor comes from the blunt literalness of Python's no-op statement being documented with a no-frills sentence that itself feels like a joke. For developers, it is a compact reminder that sometimes the most accurate specification is also the funniest one.
Use J and K for navigation
Comments
13Comment deleted
Python looked at TODO-driven development and gave it a first-class syntax node.
def func(): # TODO func() This is not gonna work. "pass" saves the day. Comment deleted
None would work too Comment deleted
Yes. In this exact case even return is fine. But pass is more obvious when you look at it later. Comment deleted
Or return Comment deleted
Or literally any literal Comment deleted
literal? Comment deleted
def foo(): "sausage" Comment deleted
Heh Comment deleted
"literally any literal" Comment deleted
Ellipsis works fine as well def foo(): … Comment deleted
++ I think ellipsis is better for empty funcs pass is better for if.else/match.case/try.except statements Comment deleted
Ich passe. (I am passing?) Comment deleted