Commit be18b176 by Ian Lance Taylor Committed by Ian Lance Taylor

re PR go/64238 (ICE in get_partitioning_class, at symtab.c:1775)

	PR go/64238
	* go-gcc.cc (Gcc_backend::implicit_variable_reference): Set
	DECL_EXTERNAL, clear TREE_STATIC.

From-SVN: r247937
parent b403beb8
2017-05-11 Ian Lance Taylor <iant@google.com>
PR go/64238
* go-gcc.cc (Gcc_backend::implicit_variable_reference): Set
DECL_EXTERNAL, clear TREE_STATIC.
2017-05-10 Than McIntosh <thanm@google.com> 2017-05-10 Than McIntosh <thanm@google.com>
* go-backend.c: Include "go-c.h". * go-backend.c: Include "go-c.h".
......
...@@ -2822,9 +2822,9 @@ Gcc_backend::implicit_variable_reference(const std::string& name, ...@@ -2822,9 +2822,9 @@ Gcc_backend::implicit_variable_reference(const std::string& name,
tree decl = build_decl(BUILTINS_LOCATION, VAR_DECL, tree decl = build_decl(BUILTINS_LOCATION, VAR_DECL,
get_identifier_from_string(name), type_tree); get_identifier_from_string(name), type_tree);
DECL_EXTERNAL(decl) = 0; DECL_EXTERNAL(decl) = 1;
TREE_PUBLIC(decl) = 1; TREE_PUBLIC(decl) = 1;
TREE_STATIC(decl) = 1; TREE_STATIC(decl) = 0;
DECL_ARTIFICIAL(decl) = 1; DECL_ARTIFICIAL(decl) = 1;
if (! asm_name.empty()) if (! asm_name.empty())
SET_DECL_ASSEMBLER_NAME(decl, get_identifier_from_string(asm_name)); SET_DECL_ASSEMBLER_NAME(decl, get_identifier_from_string(asm_name));
......
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