[PATCH] D86048: [AST][RecoveryExpr] Popagate the error-bit from a VarDecl's initializer to DeclRefExpr.

Sam McCall via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Sep 28 03:00:57 PDT 2020


sammccall accepted this revision.
sammccall added a comment.
This revision is now accepted and ready to land.

I agree with the concerns about type T not being dependent, but don't have a good suggestion of where to draw the line (introducing dependence bits for Decl is obviously a big can of worms).

However the concrete change here seems sensible to me: if value-dependence propagates from initializer to reference, then maybe so should errors? Particularly in cases of constants...
And it fixes the bug in a reasonably intuitive way: ABC<N> isn't a valid type, so any variable declared with it is invalid.

So LGTM unless @rsmith has any objections.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D86048/new/

https://reviews.llvm.org/D86048



More information about the cfe-commits mailing list