Debug info: Initialize runtime language field correctly for Objective-C

interface types.

llvm-svn: 72036
This commit is contained in:
Daniel Dunbar 2009-05-18 20:51:58 +00:00
parent 5e16fbe562
commit c61d0bd8f1
2 changed files with 10 additions and 2 deletions

View File

@ -519,7 +519,7 @@ llvm::DIType CGDebugInfo::CreateType(const ObjCInterfaceType *Ty,
unsigned Line = PLoc.isInvalid() ? 0 : PLoc.getLine();
unsigned RuntimeLang = DefUnit.getRunTimeVersion();
unsigned RuntimeLang = DefUnit.getLanguage();
// To handle recursive interface, we
// first generate a debug descriptor for the struct as a forward declaration.

View File

@ -2,9 +2,17 @@
// RUN: grep '@.str3 = internal constant \[8 x i8\] c"-\[A m0\]\\00"' %t &&
// RUN: grep '@.str4 = internal constant \[9 x i8\] c"\\01-\[A m0\]\\00"' %t &&
// RUN: grep '@llvm.dbg.subprogram = .* @.str3, .* @.str3, .* @.str4,' %t &&
// RUN: grep '@llvm.dbg.composite.* = .* i32 15, i64 0, i64 8, .* i32 16' %t &&
// RUN: true
@interface A @end
@implementation A
@implementation A // Line 15
-(void) m0 {}
@end