File tree Expand file tree Collapse file tree 2 files changed +5
-7
lines changed Expand file tree Collapse file tree 2 files changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -104,7 +104,7 @@ static bool getSymbolNameAddr(llvm::StringRef libraryName,
104104
105105 // UnDecorateSymbolName() will not fail for Swift symbols, so detect them
106106 // up-front and let Swift handle them.
107- if (!Demangle::isMangledName (syminfo. getSymbolName () )) {
107+ if (!Demangle::isMangledName (szSymbolName )) {
108108 char szUndName[1024 ];
109109 DWORD dwResult;
110110 dwResult = _swift_win32_withDbgHelpLibrary ([&] (HANDLE hProcess) -> DWORD {
@@ -117,7 +117,7 @@ static bool getSymbolNameAddr(llvm::StringRef libraryName,
117117 dwFlags |= UNDNAME_32_BIT_DECODE;
118118#endif
119119
120- return UnDecorateSymbolName (syminfo. getSymbolName () , szUndName,
120+ return UnDecorateSymbolName (szSymbolName , szUndName,
121121 sizeof (szUndName), dwFlags);
122122 });
123123
Original file line number Diff line number Diff line change @@ -72,8 +72,6 @@ const void *SymbolInfo::getSymbolAddress() const {
7272struct Win32ModuleInfo {
7373 const char *name;
7474 const void *base;
75-
76- Win32ModuleInfo (const char *n, const void *b) : name(n), base(b) {}
7775};
7876
7977// Get the filename and base of the module that contains the specified
@@ -117,17 +115,17 @@ static Win32ModuleInfo moduleInfoFromAddress(const void *address) {
117115 if (pwszFileName != wszBuffer)
118116 ::free (pwszFileName);
119117
120- return Win32ModuleInfo ( ::strdup (" <unknown>" ), mi.lpBaseOfDll ) ;
118+ return { ::strdup (" <unknown>" ), mi.lpBaseOfDll } ;
121119 }
122120
123121 const char *result = _swift_win32_copyUTF8FromWide (pwszFileName);
124122
125123 if (pwszFileName != wszBuffer)
126124 ::free ((void *)pwszFileName);
127125
128- return Win32ModuleInfo ( result, mi.lpBaseOfDll ) ;
126+ return { result, mi.lpBaseOfDll } ;
129127 } else {
130- return Win32ModuleInfo ( ::strdup (" <unknown>" ), nullptr ) ;
128+ return { ::strdup (" <unknown>" ), nullptr } ;
131129 }
132130}
133131#endif
You can’t perform that action at this time.
0 commit comments