[ASTimporter] Remove decl from lookup only if it has decl context
In the case of TypedefDecls we set the DeclContext after we imported it. It turns out, it could lead to null pointer dereferences during the cleanup part of a failed import. This patch demonstrates this issue and fixes it by checking if the DeclContext is available or not. Reviewed By: shafik Differential Revision: https://reviews.llvm.org/D102640
Loading
Please sign in to comment