OK, thanks.
Jason
On Fri, Feb 05, 2016 at 05:36:21PM -0500, Jason Merrill wrote:
> On 02/05/2016 05:32 PM, Marek Polacek wrote:
> > if (TREE_CODE (type) == ERROR_MARK)
> > return NULL_TREE;
> >
> >+ /* Here, DECL may change value; purge caches. */
> >+ clear_fold_cache ();
> >+ clear_cv_cache ();
> >+
> >
On 02/05/2016 05:32 PM, Marek Polacek wrote:
if (TREE_CODE (type) == ERROR_MARK)
return NULL_TREE;
+ /* Here, DECL may change value; purge caches. */
+ clear_fold_cache ();
+ clear_cv_cache ();
+
if (MAYBE_CLASS_TYPE_P (type))
This should happen after computing the value to be s
This issue is similar to c++/68586 -- maybe_constant_value returned stale
value for a decl from the cache. Fixed by clearing the caches when we
store init value for a decl.
Bootstrapped/regtested on x86_64-linux, ok for trunk?
2016-02-05 Marek Polacek
PR c++/69688
* typeck2.c