aaron.ballman added inline comments.
================ Comment at: clang/test/AST/Interp/records.cpp:500 namespace PointerArith { struct A {}; ---------------- shafik wrote: > aaron.ballman wrote: > > Neat! For the tests in this namespace, Clang and ICC agree, GCC and MSVC > > agree, and users get to cry: https://godbolt.org/z/7EWWrY5z6 > Yeah, unfortunate but I am pretty sure clang is correct on both of those. I think Clang is correct on one of those, but not both of them. I think Clang is correct to reject `constexpr const int *pn = &(&b + 1)->n;` as that involves dereferencing the one-past-the-end pointer, but I think Clang is wrong to reject `constexpr A *a2 = &b + 1;` as there's no dereference there. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D149149/new/ https://reviews.llvm.org/D149149 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits