Skip to content

Commit aef75f4

Browse files
committed
Default constructor, and const some stuff
1 parent 08d3126 commit aef75f4

File tree

2 files changed

+6
-7
lines changed

2 files changed

+6
-7
lines changed

lldb/source/Plugins/Process/minidump/MinidumpParser.cpp

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@
2020
#include <algorithm>
2121
#include <map>
2222
#include <optional>
23-
#include <vector>
2423
#include <utility>
24+
#include <vector>
2525

2626
using namespace lldb_private;
2727
using namespace minidump;
@@ -75,8 +75,7 @@ UUID MinidumpParser::GetModuleUUID(const minidump::Module *module) {
7575
if (GetArchitecture().GetTriple().isOSBinFormatELF()) {
7676
if (pdb70_uuid->Age != 0)
7777
return UUID(pdb70_uuid, sizeof(*pdb70_uuid));
78-
return UUID(&pdb70_uuid->Uuid,
79-
sizeof(pdb70_uuid->Uuid));
78+
return UUID(&pdb70_uuid->Uuid, sizeof(pdb70_uuid->Uuid));
8079
}
8180
return UUID(*pdb70_uuid);
8281
} else if (cv_signature == CvSignature::ElfBuildId)
@@ -432,7 +431,8 @@ MinidumpParser::FindMemoryRange(lldb::addr_t addr) {
432431
if (m_memory_ranges.IsEmpty())
433432
PopulateMemoryRanges();
434433

435-
MemoryRangeVector::Entry *entry = m_memory_ranges.FindEntryThatContains(addr);
434+
const MemoryRangeVector::Entry *entry =
435+
m_memory_ranges.FindEntryThatContains(addr);
436436
if (!entry)
437437
return std::nullopt;
438438

@@ -610,8 +610,7 @@ std::pair<MemoryRegionInfos, bool> MinidumpParser::BuildMemoryRegions() {
610610
case StreamType::ST: \
611611
return #ST
612612

613-
llvm::StringRef
614-
MinidumpParser::GetStreamTypeAsString(StreamType stream_type) {
613+
llvm::StringRef MinidumpParser::GetStreamTypeAsString(StreamType stream_type) {
615614
switch (stream_type) {
616615
ENUM_TO_CSTR(Unused);
617616
ENUM_TO_CSTR(ThreadList);

lldb/source/Plugins/Process/minidump/MinidumpParser.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ namespace minidump {
3838
struct Range {
3939
// Default constructor required for range data vector
4040
// but unusued.
41-
Range() {}
41+
Range() = default;
4242
lldb::addr_t start; // virtual address of the beginning of the range
4343
// range_ref - absolute pointer to the first byte of the range and size
4444
llvm::ArrayRef<uint8_t> range_ref;

0 commit comments

Comments
 (0)