Index: lldb/source/Plugins/TypeSystem/Clang/TypeSystemClang.cpp =================================================================== --- lldb/source/Plugins/TypeSystem/Clang/TypeSystemClang.cpp +++ lldb/source/Plugins/TypeSystem/Clang/TypeSystemClang.cpp @@ -2002,6 +2002,8 @@ ASTContext &ast = getASTContext(); if (!decl_ctx) decl_ctx = ast.getTranslationUnitDecl(); + assert(!decl_ctx->isRecord() && + "Use AddMethodToCXXRecordType to add member functions to a record"); const bool hasWrittenPrototype = true; const bool isConstexprSpecified = false;