
The only precedent that jumps out for me is itertools.chain() and
itertools.chain.from_iterable(). It's quite likely that something
I don't use much has used the same pattern though.
I think David is right: itertools.chain.from_iterable() is the only
place I know of with an attribute on a function that's another function. Alternate constructors are generally classmethods. Not that the distinction is terribly important, but it is a distinction, and it's documented differently.
I don't think being a function versus a classmethod is important here. Just that the underlying name is *callable*.
If the implementation was like this dumb example, it wouldn't matter that it was a class instance (e.g. for a hypothetical `greet` builtin)
class Greeting:
... def __call__(self, name): ... print("Hello", name) ... def twice(self, name): ... print(f"Hi {name}, howdy there!") ...
greet = Greeting() greet('Eric')
Hello Eric
greet.twice('Eric')
Hi Eric, howdy there!