File tree Expand file tree Collapse file tree 2 files changed +15
-7
lines changed
Expand file tree Collapse file tree 2 files changed +15
-7
lines changed Original file line number Diff line number Diff line change @@ -569,14 +569,8 @@ class IRGenDebugInfoImpl : public IRGenDebugInfo {
569569 if (FuncDecl *FD = L.getAsASTNode <FuncDecl>())
570570 return getName (*FD);
571571
572- if (L.isASTNode <ConstructorDecl>())
573- return " init" ;
574-
575- if (L.isASTNode <DestructorDecl>())
576- return " deinit" ;
577-
578572 if (ValueDecl *D = L.getAsASTNode <ValueDecl>())
579- return D->getBaseIdentifier ().str ();
573+ return D->getBaseName ().userFacingName ();
580574
581575 if (auto *D = L.getAsASTNode <MacroExpansionDecl>())
582576 return D->getMacroName ().getBaseIdentifier ().str ();
Original file line number Diff line number Diff line change 1+ // RUN: %target-swift-frontend %s -Onone -emit-ir -g -o - -parse-as-library -module-name a | %FileCheck %s
2+ public protocol P { }
3+ public class C : P { }
4+ public struct S { }
5+ public extension S {
6+ subscript< T> ( _ val: T , _ type : T . Type = T . self) -> T ? { return nil }
7+ }
8+
9+ public func f( ) {
10+ S ( ) [ 0 ]
11+ }
12+ // CHECK: !DISubprogram(name: "deinit"
13+ // CHECK: !DISubprogram(name: "init"
14+ // CHECK: !DISubprogram(name: "subscript
You can’t perform that action at this time.
0 commit comments