Skip to main content
2 of 2
edited body
duplode
  • 34.3k
  • 9
  • 64
  • 108

First of all, I would say it is not a very good question, and it is probably deserving of being downvoted. That doesn't automatically mean it needs to be closed, though. In the case of this specific question, a "too broad" close vote would not be unreasonable, given how many utterly trivial examples might be provided as answers (Cf. the first clause of the "too broad" reason: "There are either too many possible answers, or good answers would be too long for this format [...]").

Not all example requests, however, fall under "too broad" -- far from it. Suppose that, rather than "What is an example of a type error", the question was "What is an example of [a scenario, involving an advanced feature, that triggers a corner case the OP is worried about]?". Questions of this sort are not too broad under any reasonable definition of "too broad". Furthermore, even if one wants to be pedantic and reply with "It doesn't matter! There are infinite possible examples, and so there are infinite possible answers, which makes the question infinitely broad!", the question can be rephrased with minimal losses as "In which conditions [the corner case, etc.] is triggered?", which is not too broad under any definition, and whose answers can very naturally provide the desired examples. (Weren't it for the OP claiming that "I know what type checking is and how it works and all", such a strategy might even be tried with our concrete case, turning the question into "What is a type error in C++?", though in this case it would only lead us into arguing whether that is too broad as well.)

duplode
  • 34.3k
  • 9
  • 64
  • 108