Improve C++ fold caching efficiency.
authorJason Merrill <jason@redhat.com>
Wed, 2 Oct 2019 20:01:42 +0000 (16:01 -0400)
committerJason Merrill <jason@gcc.gnu.org>
Wed, 2 Oct 2019 20:01:42 +0000 (16:01 -0400)
commitb830c28b56fdc3f4b4555200278218b4b49022d2
treee8b1d17708df837d5cc016be4106d15e520beff0
parentc89844e5d30a5235960a2c627abc9369306fda61
Improve C++ fold caching efficiency.

While looking at concepts caching I noticed that we were clearing the caches
unnecessarily for non-constant initialization, which shouldn't affect
folding.

* typeck2.c (store_init_value): Only clear_cv_and_fold_caches if the
value is constant.

From-SVN: r276487
gcc/cp/ChangeLog
gcc/cp/typeck2.c