/cp
2011-11-24 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/51290
* class.c (build_base_path): For the null pointer check use
nullptr_node instead of integer_zero_node.
/testsuite
2011-11-24 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/51290
* g++.dg/warn/Wzero-as-null-pointer-constant-3.C: New.
From-SVN: r181690
+2011-11-24 Paolo Carlini <paolo.carlini@oracle.com>
+
+ PR c++/51290
+ * class.c (build_base_path): For the null pointer check use
+ nullptr_node instead of integer_zero_node.
+
2011-11-22 Dodji Seketeli <dodji@redhat.com>
PR c++/51145
/* Now that we've saved expr, build the real null test. */
if (null_test)
{
- tree zero = cp_convert (TREE_TYPE (expr), integer_zero_node);
+ tree zero = cp_convert (TREE_TYPE (expr), nullptr_node);
null_test = fold_build2_loc (input_location, NE_EXPR, boolean_type_node,
expr, zero);
}
+2011-11-24 Paolo Carlini <paolo.carlini@oracle.com>
+
+ PR c++/51290
+ * g++.dg/warn/Wzero-as-null-pointer-constant-3.C: New.
+
2011-11-23 Jakub Jelinek <jakub@redhat.com>
PR target/51261
--- /dev/null
+// PR c++/51290
+// { dg-options "-Wzero-as-null-pointer-constant" }
+
+class A { int a; };
+
+class B { int b; };
+
+class C : public A, public B
+{
+ private:
+ static void foo (A *x)
+ {
+ C *y = static_cast<C *>(x);
+ (void) y;
+ }
+
+ static void bar (B *x)
+ {
+ C *y = static_cast<C *>(x);
+ (void) y;
+ }
+};