LLDB mainline
OptionGroupMemoryTag.cpp
Go to the documentation of this file.
1//===-- OptionGroupMemoryTag.cpp -----------------------------------------===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8
10
12
13using namespace lldb;
14using namespace lldb_private;
15
16static const uint32_t SHORT_OPTION_SHOW_TAGS = 0x54414753; // 'tags'
17
19 : m_show_tags(false, false), m_option_definition{
21 false,
22 "show-tags",
24 OptionParser::eNoArgument,
25 nullptr,
26 {},
27 0,
29 note_binary
30 ? "Include memory tags in output "
31 "(does not apply to binary output)."
32 : "Include memory tags in output."} {}
33
34llvm::ArrayRef<OptionDefinition> OptionGroupMemoryTag::GetDefinitions() {
35 return llvm::ArrayRef(m_option_definition);
36}
37
40 llvm::StringRef option_arg,
41 ExecutionContext *execution_context) {
42 assert(option_idx == 0 && "Only one option in memory tag group!");
43
48 break;
49
50 default:
51 llvm_unreachable("Unimplemented option");
52 }
53
54 return {};
55}
56
58 ExecutionContext *execution_context) {
60}
static const uint32_t SHORT_OPTION_SHOW_TAGS
"lldb/Target/ExecutionContext.h" A class that contains an execution context.
void OptionParsingStarting(ExecutionContext *execution_context) override
OptionGroupMemoryTag(bool note_binary=false)
llvm::ArrayRef< OptionDefinition > GetDefinitions() override
Status SetOptionValue(uint32_t option_idx, llvm::StringRef option_value, ExecutionContext *execution_context) override
An error handling class.
Definition: Status.h:44
#define LLDB_OPT_SET_1
Definition: lldb-defines.h:111
A class that represents a running process on the host machine.
Definition: SBAddress.h:15
int short_option
Single character for this option.