If we find an error in the range expression in a range-based for loop, and the
authorRichard Smith <richard-llvm@metafoo.co.uk>
Wed, 21 Aug 2013 01:40:36 +0000 (01:40 +0000)
committerRichard Smith <richard-llvm@metafoo.co.uk>
Wed, 21 Aug 2013 01:40:36 +0000 (01:40 +0000)
commit3249fed9b2c89f1e09b1f0bd9934472eaf316e6d
tree6bbd93934affaa4cc525429bb3b096b337f7074d
parent84a0ae74b0f519a46f85495410ab2092718f55ba
If we find an error in the range expression in a range-based for loop, and the
loop variable has a type containing 'auto', set the declaration to be invalid
(because we couldn't deduce its type) to prevent follow-on errors.

llvm-svn: 188853
clang/lib/Sema/SemaStmt.cpp
clang/test/SemaCXX/cxx11-crashes.cpp
clang/test/SemaCXX/for-range-examples.cpp