Commit 15eb1e43 by Jason Merrill

decl2.c (coerce_new_type): Downgrade error for size_t mismatch to pedwarn.

        * decl2.c (coerce_new_type): Downgrade error for size_t mismatch
        to pedwarn.

        * method.c (make_thunk): If !flag_weak, give the thunk the
        function's linkage.
        (use_thunk): Here, too.

From-SVN: r48613
parent 20e26713
2002-01-07 Jason Merrill <jason@redhat.com>
* decl2.c (coerce_new_type): Downgrade error for size_t mismatch
to pedwarn.
* method.c (make_thunk): If !flag_weak, give the thunk the
function's linkage.
(use_thunk): Here, too.
2002-01-07 Graham Stott <grahams@redhat.com> 2002-01-07 Graham Stott <grahams@redhat.com>
* error.c: Update copyright date. * error.c: Update copyright date.
...@@ -221,7 +230,7 @@ ...@@ -221,7 +230,7 @@
2002-01-05 Richard Henderson <rth@redhat.com> 2002-01-05 Richard Henderson <rth@redhat.com>
* semantics.c (expand_body): Revert last change. * semantics.c (expand_body): Revert last change.
2002-01-04 Jason Merrill <jason@redhat.com> 2002-01-04 Jason Merrill <jason@redhat.com>
......
...@@ -2064,7 +2064,7 @@ coerce_new_type (type) ...@@ -2064,7 +2064,7 @@ coerce_new_type (type)
e = 2; e = 2;
if (args && args != void_list_node) if (args && args != void_list_node)
args = TREE_CHAIN (args); args = TREE_CHAIN (args);
error ("`operator new' takes type `size_t' (`%T') as first parameter", c_size_type_node); pedwarn ("`operator new' takes type `size_t' (`%T') as first parameter", c_size_type_node);
} }
switch (e) switch (e)
{ {
......
...@@ -338,7 +338,9 @@ make_thunk (function, delta, vcall_index) ...@@ -338,7 +338,9 @@ make_thunk (function, delta, vcall_index)
DECL_CONTEXT (thunk) = DECL_CONTEXT (func_decl); DECL_CONTEXT (thunk) = DECL_CONTEXT (func_decl);
TREE_READONLY (thunk) = TREE_READONLY (func_decl); TREE_READONLY (thunk) = TREE_READONLY (func_decl);
TREE_THIS_VOLATILE (thunk) = TREE_THIS_VOLATILE (func_decl); TREE_THIS_VOLATILE (thunk) = TREE_THIS_VOLATILE (func_decl);
comdat_linkage (thunk); TREE_PUBLIC (thunk) = TREE_PUBLIC (func_decl);
if (flag_weak)
comdat_linkage (thunk);
SET_DECL_THUNK_P (thunk); SET_DECL_THUNK_P (thunk);
DECL_INITIAL (thunk) = function; DECL_INITIAL (thunk) = function;
THUNK_DELTA (thunk) = d; THUNK_DELTA (thunk) = d;
...@@ -409,6 +411,9 @@ use_thunk (thunk_fndecl, emit_p) ...@@ -409,6 +411,9 @@ use_thunk (thunk_fndecl, emit_p)
mark_used (thunk_fndecl); mark_used (thunk_fndecl);
/* This thunk is actually defined. */ /* This thunk is actually defined. */
DECL_EXTERNAL (thunk_fndecl) = 0; DECL_EXTERNAL (thunk_fndecl) = 0;
/* The linkage of the function may have changed. FIXME in linkage
rewrite. */
TREE_PUBLIC (thunk_fndecl) = TREE_PUBLIC (function);
if (flag_syntax_only) if (flag_syntax_only)
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment