hubert.reinterpretcast added inline comments. ================ Comment at: lib/AST/ASTContext.cpp:4635 @@ +4634,3 @@ + // If the two sides have Float128Rank and LongDoubleRank and the two types + // have the same representation on this platform, they have equal rank. + if ((LHSR == LongDoubleRank && RHSR == Float128Rank) || ---------------- rjmccall wrote: > This is a really bad language rule with nasty implications for a lot of code. > Is there a really urgent need to emulate some other compiler bug-for-bug > here? > > It's okay for there to a formal rank difference even when types have the same > representation — that's basically always true for the integer types — so > unless there's a very specific and very good reason not to, let's just use > the rule that float128 has higher rank than long double. I am not very keen on the [[ http://reviews.llvm.org/D15120#inline-133280 | implications ]] of having the equal rank either.
I believe the case where neither type represents the full set of values of the other should be considered "unordered" though (currently that is handled by `typesNotCompatible()`, which is in need of a better name since the function does not deal with "compatible types" as defined by C11 subclause 6.2.7). Repository: rL LLVM http://reviews.llvm.org/D15120 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits