Fix Sema::MergeVarDecl() to better handle type compatibility. The previous code was trying to handle arrays specially (which didn't work for pointers to array). Removed local helper function areEquivalentArrayTypes(), replacing it's use with the more general ASTContext::typesAreCompatible() predicate.

Even though the test case this fixes is in "tentative-decls.c", this bug didn't have anything to do with our handling of tentative definitions (which is what I first expected). In any event, this is a tricky area of the spec.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@54583 91177308-0d34-0410-b5e6-96231b3b80d8
2 files changed