Skip to content

Commit e4386fa

Browse files
committed
Disable assertion
hotfix for rdar://82037935
1 parent fe2172a commit e4386fa

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

clang/include/clang/AST/DeclContextInternals.h

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,11 @@ class StoredDeclsList {
238238

239239
// FIXME: Move the assert before the single decl case when we fix the
240240
// duplication coming from the ASTReader reading builtin types.
241-
assert(!llvm::is_contained(getLookupResult(), D) && "Already exists!");
241+
242+
// SWIFT: FIXME^2: This assertion causes problems in Swift's ClangImporter.
243+
// SWIFT: We should probably set its ASTContext to Objective-C++ mode to avoid it.
244+
// SWIFT: assert(!llvm::is_contained(getLookupResult(), D) && "Already exists!");
245+
242246
// Determine if this declaration is actually a redeclaration.
243247
for (DeclListNode *N = getAsList(); /*return in loop*/;
244248
N = N->Rest.dyn_cast<DeclListNode *>()) {

0 commit comments

Comments
 (0)