]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
typeck.c (common_type): Use same_type_p.
authorJason Merrill <jason@yorick.cygnus.com>
Mon, 9 Aug 1999 00:28:35 +0000 (00:28 +0000)
committerJason Merrill <jason@gcc.gnu.org>
Mon, 9 Aug 1999 00:28:35 +0000 (20:28 -0400)
* typeck.c (common_type): Use same_type_p.

and revert:
  * decl.c (bad_specifiers): It's OK to have an EH spec on a function
pointer.

From-SVN: r28607

gcc/cp/ChangeLog
gcc/cp/decl.c
gcc/cp/typeck.c

index bfebb6e241b9c0e1f0d5c201fea2630fe3b7b0a6..7f45b354dbe71d327f47d7ed7756a869264359a4 100644 (file)
@@ -1,7 +1,8 @@
-1999-08-06  Jason Merrill  <jason@yorick.cygnus.com>
+1999-08-08  Jason Merrill  <jason@yorick.cygnus.com>
+
+       * typeck.c (common_type): Use same_type_p.
 
-       * decl.c (bad_specifiers): It's OK to have an EH spec on a function
-       pointer.
+1999-08-06  Jason Merrill  <jason@yorick.cygnus.com>
 
        * pt.c (maybe_get_template_decl_from_type_decl): Make sure that
        we're looking at a class.
@@ -59,10 +60,6 @@ Wed Jul 28 21:39:31 PDT 1999 Jeff Law  (law@cygnus.com)
 
        * gcc-2.95 Released.
 
-Sun Jul 25 23:40:51 PDT 1999 Jeff Law  (law@cygnus.com)
-
-       * gcc-2.95 Released.
-
 Sun Jul 25 15:24:21 1999  Jeffrey A Law  (law@cygnus.com)
 
        * g++FAQ.texi: Deleted per Joe Buck's request.
index ea472082e19ff2f3065be0a1e745d09c5c76cd1c..c60acc7b80d057c394c0b4099b27bad1202c48f5 100644 (file)
@@ -8709,9 +8709,9 @@ bad_specifiers (object, type, virtualp, quals, inlinep, friendp, raises)
     cp_error ("`const' and `volatile' function specifiers on `%D' invalid in %s declaration",
              object, type);
   if (friendp)
-    cp_error_at ("`%D' declared as a friend", object);
-  if (raises && ! TYPE_PTRFN_P (TREE_TYPE (object)))
-    cp_error_at ("`%D' declared with an exception specification", object);
+    cp_error_at ("invalid friend declaration", object);
+  if (raises)
+    cp_error_at ("invalid exception specifications", object);
 }
 
 /* CTYPE is class type, or null if non-class.
index d0743e950f40b2c56a8f69920a5e90a6feb389f2..f1c8a1ff5a887545f6f519bc9492d4fad9117c44 100644 (file)
@@ -582,7 +582,7 @@ common_type (t1, t2)
        tt1 = TYPE_MAIN_VARIANT (tt1);
        tt2 = TYPE_MAIN_VARIANT (tt2);
 
-       if (tt1 == tt2)
+       if (same_type_p (tt1, tt2))
          target = tt1;
        else if (b1)
          {