diff options
author | Ian Lance Taylor <ian@gcc.gnu.org> | 2019-10-14 23:12:33 +0000 |
---|---|---|
committer | Ian Lance Taylor <ian@gcc.gnu.org> | 2019-10-14 23:12:33 +0000 |
commit | 0a0582d75efb699d9adacc7a89831e90c4bd6c1d (patch) | |
tree | 1fb29f4498730515575d77c0b16d9cf7ab1823ba | |
parent | 4a4fc7feda04b57e3bf767ba29836868f2f984d7 (diff) | |
download | gcc-0a0582d75efb699d9adacc7a89831e90c4bd6c1d.zip gcc-0a0582d75efb699d9adacc7a89831e90c4bd6c1d.tar.gz gcc-0a0582d75efb699d9adacc7a89831e90c4bd6c1d.tar.bz2 |
compiler: revise exportdata fix for processing constant types
This patch is an addendum to the fix for issue 34577, which was not
sufficiently general. During export data processing, when looking at
the types of constants mentioned in inlinable function bodies, include
both locally defined constants and constant imported from other
packages.
Testcase for this bug is in CL 201017.
Fixes golang/go#34852.
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/201018
From-SVN: r276976
-rw-r--r-- | gcc/go/gofrontend/MERGE | 2 | ||||
-rw-r--r-- | gcc/go/gofrontend/export.cc | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/gcc/go/gofrontend/MERGE b/gcc/go/gofrontend/MERGE index 651f7473..c9efcba 100644 --- a/gcc/go/gofrontend/MERGE +++ b/gcc/go/gofrontend/MERGE @@ -1,4 +1,4 @@ -f71238c0112311e4525a1f4b76d2f80be87d2e62 +1e2d98b27701744cf0ec57b19d7fc8f594184b9a The first line of this file holds the git revision number of the last merge done from the gofrontend repository. diff --git a/gcc/go/gofrontend/export.cc b/gcc/go/gofrontend/export.cc index 5aaa207..b27d2fa 100644 --- a/gcc/go/gofrontend/export.cc +++ b/gcc/go/gofrontend/export.cc @@ -250,7 +250,7 @@ Collect_export_references::expression(Expression** pexpr) } const Named_object* nco = expr->named_constant(); - if (nco != 0 && nco->package() == NULL) + if (nco != 0) { const Named_constant *nc = nco->const_value(); Type::traverse(nc->type(), this); |