This is the mail archive of the
gcc-cvs@gcc.gnu.org
mailing list for the GCC project.
r269634 - in /trunk/gcc/go/gofrontend: MERGE ex...
- From: ian at gcc dot gnu dot org
- To: gcc-cvs at gcc dot gnu dot org
- Date: Wed, 13 Mar 2019 05:12:05 -0000
- Subject: r269634 - in /trunk/gcc/go/gofrontend: MERGE ex...
Author: ian
Date: Wed Mar 13 05:12:05 2019
New Revision: 269634
URL: https://gcc.gnu.org/viewcvs?rev=269634&root=gcc&view=rev
Log:
compiler: compare parse methods when indexing interface types for export
This change fixes a bug in which two interface types were being
incorrectly commoned (considered identical) in the initial stages of
writing out types to export data. The indexer does a walk to collect
candidates for export, inserting types into a table to eliminate
duplicates; as part of this process a local interface type T1 was
being commoned with a different interface type T2. This caused a cycle
in the exported type graph due to the way embedded interfaces are
handled.
The fix was to add a new flag to the Type::is_identical utility
routine to request that interface type comparison be done by examining
the original parse methods, as opposed to the expanded method set,
then use the new flag when creating the hash map for the exporter.
Fixes golang/go#30659.
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/166638
Modified:
trunk/gcc/go/gofrontend/MERGE
trunk/gcc/go/gofrontend/export.cc
trunk/gcc/go/gofrontend/types.cc
trunk/gcc/go/gofrontend/types.h