[Lldb-commits] [lldb] [lldb-dap] Reuse source object logics (PR #141426)
Jonas Devlieghere via lldb-commits
lldb-commits at lists.llvm.org
Thu May 29 22:35:41 PDT 2025
================
@@ -558,28 +559,30 @@ protocol::Source CreateAssemblySource(const lldb::SBTarget &target,
return source;
}
-bool ShouldDisplayAssemblySource(
- const lldb::SBLineEntry &line_entry,
- lldb::StopDisassemblyType stop_disassembly_display) {
- if (stop_disassembly_display == lldb::eStopDisassemblyTypeNever)
- return false;
-
- if (stop_disassembly_display == lldb::eStopDisassemblyTypeAlways)
- return true;
-
- // A line entry of 0 indicates the line is compiler generated i.e. no source
- // file is associated with the frame.
- auto file_spec = line_entry.GetFileSpec();
- if (!file_spec.IsValid() || line_entry.GetLine() == 0 ||
- line_entry.GetLine() == LLDB_INVALID_LINE_NUMBER)
- return true;
+protocol::Source CreateSource(const lldb::SBFileSpec &file) {
----------------
JDevlieghere wrote:
Should this now live in ProtocolUtils?
https://github.com/llvm/llvm-project/pull/141426
More information about the lldb-commits
mailing list