Revert a change from r222797 that is no longer needed and can cause
authorKaelyn Takata <rikka@google.com>
Wed, 28 Jan 2015 21:10:46 +0000 (21:10 +0000)
committerKaelyn Takata <rikka@google.com>
Wed, 28 Jan 2015 21:10:46 +0000 (21:10 +0000)
commitc49838b33155a93ca83d3cc2279211ac2665da31
treeb4d4f42ee3db8c7015ace6fdd06571c6ed4ca879
parent48eec8a90d9ba434c3ae6687bd290c6014bef928
Revert a change from r222797 that is no longer needed and can cause
infinite recursion.

Also guard against said infinite recursion by adding an assert that will
trigger if CorrectDelayedTyposInExpr is called before a previous call to
CorrectDelayedTyposInExpr returns (i.e. if the TreeTransform run by
CorrectDelayedTyposInExpr calls a sequence of methods that
end up calling CorrectDelayedTyposInExpr, as the new test case had done
prior to this commit). Fixes PR22292.

llvm-svn: 227368
clang/lib/Sema/SemaExpr.cpp
clang/lib/Sema/SemaExprCXX.cpp
clang/test/SemaCXX/typo-correction-delayed.cpp