When reading the AST, delay loading of the redeclaration chain to avoid deeply nested...
commit50d25888baa7ca20a30e8422990df2dbd4bba6e1
authorArgiris Kirtzidis <akyrtzi@gmail.com>
Sat, 12 Feb 2011 07:50:47 +0000 (12 07:50 +0000)
committerArgiris Kirtzidis <akyrtzi@gmail.com>
Sat, 12 Feb 2011 07:50:47 +0000 (12 07:50 +0000)
tree6f76a9c8f552636758c37d4e20730e3a83b0f2a6
parentf3a4ff870237466fc47ad7122d87ed80acf6da1d
When reading the AST, delay loading of the redeclaration chain to avoid deeply nested calls.
Temporarily set the first (canonical) declaration as the previous one, which is the one that
matters, and mark the real previous DeclID to be loaded & attached later on.

Fixes rdar://8956193.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125434 91177308-0d34-0410-b5e6-96231b3b80d8
include/clang/Serialization/ASTReader.h
lib/Serialization/ASTReader.cpp
lib/Serialization/ASTReaderDecl.cpp
lib/Serialization/ASTWriterDecl.cpp
test/Index/c-index-redecls.c [new file with mode: 0644]