File tree 2 files changed +16
-11
lines changed
lldb/source/Plugins/Language/Swift 2 files changed +16
-11
lines changed Original file line number Diff line number Diff line change @@ -1832,16 +1832,20 @@ SwiftLanguage::GetDemangledFunctionNameWithoutArguments(Mangled mangled) const {
1832
1832
return mangled_name;
1833
1833
}
1834
1834
1835
- bool SwiftLanguage::IgnoreForLineBreakpoints (const SymbolContext &sc) const {
1836
- // If we don't have a function, conservatively return false.
1837
- if (!sc.function )
1838
- return false ;
1839
- llvm::StringRef name =
1840
- sc.function ->GetMangled ().GetMangledName ().GetStringRef ();
1841
- // In async functions, ignore await resume ("Q") funclets, these only
1842
- // deallocate the async context and task_switch back to user code.
1843
- return SwiftLanguageRuntime::IsSwiftAsyncAwaitResumePartialFunctionSymbol (
1844
- name);
1835
+ void SwiftLanguage::FilterForLineBreakpoints (
1836
+ llvm::SmallVectorImpl<SymbolContext> &sc_list) const {
1837
+ llvm::erase_if (sc_list, [](const SymbolContext &sc) {
1838
+ // If we don't have a function, conservatively keep this sc.
1839
+ if (!sc.function )
1840
+ return false ;
1841
+
1842
+ // In async functions, ignore await resume ("Q") funclets, these only
1843
+ // deallocate the async context and task_switch back to user code.
1844
+ llvm::StringRef name =
1845
+ sc.function ->GetMangled ().GetMangledName ().GetStringRef ();
1846
+ return SwiftLanguageRuntime::IsSwiftAsyncAwaitResumePartialFunctionSymbol (
1847
+ name);
1848
+ });
1845
1849
}
1846
1850
1847
1851
std::optional<bool >
Original file line number Diff line number Diff line change @@ -97,7 +97,8 @@ class SwiftLanguage : public Language {
97
97
llvm::StringRef GetInstanceVariableName () override { return " self" ; }
98
98
99
99
// / Override that skips breakpoints inside await resume ("Q") async funclets.
100
- bool IgnoreForLineBreakpoints (const SymbolContext &sc) const override ;
100
+ void FilterForLineBreakpoints (
101
+ llvm::SmallVectorImpl<SymbolContext> &) const override ;
101
102
102
103
// ------------------------------------------------------------------
103
104
// PluginInterface protocol
You can’t perform that action at this time.
0 commit comments