There are times when two identical answers apply to fundamentally different questions. The best example I can think of would pertain to compilers, and the hundreds of options that one can pass to them.
I could, conceivably tell someone that -Wall
doesn't mean all warnings and that they should be using -Wextra
during debug builds to catch something. That could be my answer to someone asking about type-punned pointers, and someone asking about if compilers can catch statements that should probably be conditionals, or at least a major part of my answer.
The questions, however, could not be further from identical. They're not asking the same question even though the same answer essentially applies to both. That's not to say that similarity of answers when you're not certain can't be a guiding factor - it often is, especially if the question you're considering closing is vague, incomplete, or otherwise not asked very well.
It's hard to give a definite formula on how to spot exact or near duplicates, because context is king and varies wildly. You might have the same question but completely different constraints - platform, endianness .. it's varied. Two identical sorting questions become vastly different when you add different time/space complexity constraints. That leads me to the best advice I can possibly give, and the advice I followed for over two years serving as your moderator:
When in doubt, don't.
There are plenty of clear cases, where there's just no possibility of additional complexity creeping in. "Headers already sent by [PHP]" is a classic case of this. "Can't free const variable [C]" is another. When the only thing different is the code demonstrating the problem, and all platform/version/endian/complexity constraints be damned, it's still a duplicate, then mark it as such.
Just read both questions very carefully, look for something in the target that isn't in the source (and the reverse of that) and use your best judgement. If you're not sure, just move on - let someone else make the call.
Over the course of the next few weeks we're going to be making even more drastic improvements to how duplicates are handled. From creature comforts to guard rails designed to protect corner cases better - it will be a much saner process, for everyone. There's nothing wrong with leaving something that you're pretty sure is a dupe, we'll catch it soon enough if it is.