Changeset View
Changeset View
Standalone View
Standalone View
test/CodeGenCXX/debug-info-nodebug.cpp
Show All 38 Lines | void func3() { | ||||
S2 junk; | S2 junk; | ||||
func1(S2::static_const_member); | func1(S2::static_const_member); | ||||
} | } | ||||
// YESINFO-DAG: !DIGlobalVariable(name: "static_member" | // YESINFO-DAG: !DIGlobalVariable(name: "static_member" | ||||
// NOINFO-NOT: !DIGlobalVariable(name: "static_member" | // NOINFO-NOT: !DIGlobalVariable(name: "static_member" | ||||
// YESINFO-DAG: !DIDerivedType({{.*}} name: "static_const_member" | // YESINFO-DAG: !DIDerivedType({{.*}} name: "static_const_member" | ||||
// NOINFO-NOT: !DIDerivedType({{.*}} name: "static_const_member" | // NOINFO-NOT: !DIDerivedType({{.*}} name: "static_const_member" | ||||
// Function-local static variable. | // Function-local static, const, and normal variables. | ||||
void func4() { | void func4() { | ||||
NODEBUG static int static_local = 6; | NODEBUG static int static_local = 6; | ||||
NODEBUG const int const_local = 7; | |||||
dblaikie: Doesn't look like the const case is any different from the non-const case, is it? | |||||
Not Done ReplyInline ActionsGiven a white-box analysis of the compiler internals, you are correct; this is in contrast to the static const/non-const handling, which *does* use different paths. probinson: Given a white-box analysis of the compiler internals, you are correct; this is in contrast to… | |||||
Not Done ReplyInline Actionsconst case removed. probinson: const case removed. | |||||
NODEBUG int normal_local = 8; | |||||
} | } | ||||
// YESINFO-DAG: !DIGlobalVariable(name: "static_local" | // YESINFO-DAG: !DIGlobalVariable(name: "static_local" | ||||
// NOINFO-NOT: !DIGlobalVariable(name: "static_local" | // NOINFO-NOT: !DIGlobalVariable(name: "static_local" | ||||
// YESINFO-DAG: !DILocalVariable(name: "const_local" | |||||
// NOINFO-NOT: !DILocalVariable(name: "const_local" | |||||
// YESINFO-DAG: !DILocalVariable(name: "normal_local" | |||||
// NOINFO-NOT: !DILocalVariable(name: "normal_local" |
Doesn't look like the const case is any different from the non-const case, is it?