* Go patch committed: Don't set TYPE_STRING_FLAG on a type variant
@ 2015-12-01 4:46 Ian Lance Taylor
0 siblings, 0 replies; only message in thread
From: Ian Lance Taylor @ 2015-12-01 4:46 UTC (permalink / raw)
To: gcc-patches, gofrontend-dev
[-- Attachment #1: Type: text/plain, Size: 551 bytes --]
PR 68477 observes that gccgo crashes when using -flto1 because a type
variant has TYPE_STRING_FLAG set. So, don't do that.
TYPE_STRING_FLAG doesn't really do anything, as far as I can tell,
since all the relevant tests in dwarf2out.c also test isfortran().
But, it seems like the right thing to do. Bootstrapped and ran Go
testsuite on x86_64-pc-linux-gnu. Committed to mainline.
Ian
2015-11-30 Ian Lance Taylor <iant@google.com>
PR go/68477
* go-gcc.cc (Gcc_backend::string_constant_expression): Don't set
TYPE_STRING_FLAG on a variant type.
[-- Attachment #2: patch.txt --]
[-- Type: text/plain, Size: 595 bytes --]
Index: gcc/go/go-gcc.cc
===================================================================
--- gcc/go/go-gcc.cc (revision 230759)
+++ gcc/go/go-gcc.cc (working copy)
@@ -1279,7 +1279,6 @@ Gcc_backend::string_constant_expression(
tree const_char_type = build_qualified_type(unsigned_char_type_node,
TYPE_QUAL_CONST);
tree string_type = build_array_type(const_char_type, index_type);
- string_type = build_variant_type_copy(string_type);
TYPE_STRING_FLAG(string_type) = 1;
tree string_val = build_string(val.length(), val.data());
TREE_TYPE(string_val) = string_type;
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2015-12-01 4:46 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-12-01 4:46 Go patch committed: Don't set TYPE_STRING_FLAG on a type variant Ian Lance Taylor
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).