t.p.northover added inline comments.
================
Comment at: clang/test/CodeGenCXX/new-overflow.cpp:88
// CHECK: [[N:%.*]] = sext i16 {{%.*}} to i32
- // CHECK-NEXT: [[T0:%.*]] = icmp slt i32 [[N]], 0
- // CHECK-NEXT: [[T1:%.*]] = select i1 [[T0]], i32 -1, i32 [[N]]
- // CHECK-NEXT: call i8* @_Znaj(i32 [[T1]])
+ // CHECK-NEXT: call i8* @_Znaj(i32 [[N]])
// CHECK: getelementptr inbounds {{.*}}, i32 [[N]]
----------------
rsmith wrote:
> The changes in this file are a regression; C++14 requires us to check whether
> the array bound prior to promotion is negative. Can you file a bug on that?
I've filed https://llvm.org/PR35573. Not quite sure what to do about this test
until it's fixed though. Add a second RUN line to check both variants and then
XFAIL it?
================
Comment at: clang/test/CodeGenCXX/vtable-available-externally.cpp:275
struct C {
virtual D& operator=(const D&);
};
----------------
rsmith wrote:
> To make this test work in C++11 onwards, you need to add a virtual move
> assignment operator here:
>
> ```
> virtual D& operator=(D&&);
> ```
That didn't quite work. The issue appears to be that D has both of those
implicitly defined in C++14 mode, but only the move assignment operator is used
below. Speculative VTable emission requires all of them to be used.
So adding a "d = d;" line to the second g function fixes the test. Does that
sound sane to you, or am I missing the point?
================
Comment at: clang/test/SemaCXX/unknown-type-name.cpp:98
-template<typename T> int junk1(T::junk); // expected-warning{{variable
templates are a C++14 extension}}
+template<typename T> int junk1(T::junk);
+#if __cplusplus <= 201103L
----------------
rsmith wrote:
> Huh, we should probably have a `-Wvexing-parse` warning for this. Can you
> file a bug?
I've filed https://llvm.org/PR35576. You may want to sanity check it though, I
was pretty light on the detail because I wasn't sure of the exact diagnostic
being proposed.
Repository:
rC Clang
https://reviews.llvm.org/D40948
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits