Steven D'Aprano <steve <at> pearwood.info> writes: > > I think you're exaggerating a tad here. Why would you be "very confused" > when you see TITLEPATTERN() or foo(callback=TITLEPATTERN)? What else > would TITLEPATTERN be but a callable when it's being used as a > callable? The real problem is this example is not the fact that there is a lambda, but that the variable name doesn't reflect it is a callable. It is common practice to use verbs for callables, and nouns for non-callables. Thus I'd expect the variable to be called something like make_title_pattern rather than TITLEPATTERN (and what's with the ugly allcaps by the way?). Antoine.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4