I found this exciting gem today. This tag has 1,542 questions, at the time of writing. The excerpt for the functor tag starts with
The term 'functor' has several common meanings: 1. Function object. In object-oriented languages, it is a feature that allows objects to be used as if they were ordinary functions. 2. A mathematical structure which deals with mappings between categories. This concept is a useful abstraction in some programming languages, notably Haskell, where it is implemented as a type class. 3. In OCaml, a module that takes another module as an argument.
I see at least three separate meanings here. And in the full tag wiki page, a fourth meaning is listed.
The term "functor" in C++, which means "an object that can be called like a function". This use is pretty well-captured by function-object if you ask me. 737 of the functor-tagged questions are also tagged c++.
Functors in OCaml, which are modules parameterized by other modules. Basically, in OCaml, a functor is a function from modules to modules. 83 questions tagged with functor are also tagged ocaml, though several of those are "why doesn't OCaml have Haskell-like functors" or similar.
Functors in Haskell, which provide the
fmap
higher-order function for lifting functions to operate over some given datatype. 460 questions tagged functor are also tagged haskell, and 64 more are tagged scala, where usage is similar.In Prolog, the word "functor" refers to the head of an M-expression, so in
foo(bar, baz)
, we callfoo
the "functor" of the expression. 15 questions tagged functor are also tagged prolog.
And then there are functors in category theory (i.e. homomorphisms between categories). This is very similar to the Haskell usage, but could also be considered its own thing.
That leaves 185 questions tagged with functor and none of the mentioned languages, which seem to be a mix of (1) and (3) from people trying to apply one of those two definitions of functor to their favorite language.
I don't think we should simply get rid of the tag, because it does provide value. But something does need to be done, because right now the tag means at least four distinct things.
For completeness, the burnination criteria. As I said, I don't think burnination is the right solution, but nonetheless
Does it describe the contents of the questions to which it is applied? and is it unambiguous? No, it is quite ambiguous, which is the problem.
Is the concept described even on-topic for the site? Certainly. The C++, OCaml, and Haskell meanings are clearly on-topic. The Prolog meaning is of questionable value but is fairly niche to begin with.
Does the tag add any meaningful information to the post? Right now, not really. At a glance, it means multiple completely distinct things. But I believe that it could, if disambiguated.
Does it mean the same thing in all common contexts? This is fundamentally the problem here. We've got several meanings under one massive umbrella.