Commit 8bc7a740 by Mohan Embar Committed by Mohan Embar

re PR middle-end/12548 ([non-weak] gcj now failes to compile included example)

  PR java/12548
  * resource.c (write_resource_constructor): Append
  "_resource" to constructor identifier name.

From-SVN: r73940
parent c3786c3e
2003-11-25 Mohan Embar <gnustuff@thisiscool.com>
PR java/12548
* resource.c (write_resource_constructor): Append
"_resource" to constructor identifier name.
2003-11-25 Jeff Sturm <jsturm@one-point.com> 2003-11-25 Jeff Sturm <jsturm@one-point.com>
Fix PR java/13183. Fix PR java/13183.
......
...@@ -105,12 +105,16 @@ write_resource_constructor (void) ...@@ -105,12 +105,16 @@ write_resource_constructor (void)
tree init_name, init_type, init_decl; tree init_name, init_type, init_decl;
tree iter; tree iter;
location_t saved_loc = input_location; location_t saved_loc = input_location;
char *resource_ctor_name;
/* Only do work if required. */ /* Only do work if required. */
if (resources == NULL_TREE) if (resources == NULL_TREE)
return; return;
init_name = get_file_function_name ('I'); resource_ctor_name = concat (IDENTIFIER_POINTER (get_file_function_name ('I')),
"_resource", NULL);
init_name = get_identifier (resource_ctor_name);
free (resource_ctor_name);
init_type = build_function_type (void_type_node, end_params_node); init_type = build_function_type (void_type_node, end_params_node);
init_decl = build_decl (FUNCTION_DECL, init_name, init_type); init_decl = build_decl (FUNCTION_DECL, init_name, init_type);
......
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