llvm-project/clang/test/CXX/stmt.stmt
Haojian Wu 89d9912cbf [AST] dont invaliate VarDecl when the initializer contains errors.
Summary:
This patch contains 2 separate changes:
1) the initializer of a variable should play no part in decl "invalid" bit;
2) preserve the invalid initializer via recovery exprs;

With 1), we will regress the diagnostics (one big regression is that we loose
the "selected 'begin' function with iterator type" diagnostic in for-range stmt;
but with 2) together, we don't have regressions (the new diagnostics seems to be
improved).

Reviewers: sammccall

Reviewed By: sammccall

Subscribers: cfe-commits

Tags: #clang

Differential Revision: https://reviews.llvm.org/D78116
2020-04-21 10:53:35 +02:00
..
stmt.ambig
stmt.dcl
stmt.iter/stmt.ranged [AST] dont invaliate VarDecl when the initializer contains errors. 2020-04-21 10:53:35 +02:00
stmt.label
stmt.select Refactor the way we handle diagnosing unused expression results. 2019-01-04 16:58:14 +00:00