Skip to content

Commit 031ee14

Browse files
committed
addressed review comments
1 parent 00bf711 commit 031ee14

File tree

2 files changed

+16
-14
lines changed

2 files changed

+16
-14
lines changed

lldb/include/lldb/Core/Telemetry.h

Lines changed: 15 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ struct LLDBConfig : public ::llvm::telemetry::Config {
3434
// If true, we will collect full details about a debug command (eg., args and
3535
// original command). Note: This may contain PII, hence can only be enabled by
3636
// the vendor while creating the Manager.
37-
const bool m_detailed_command_telemetry;
37+
const bool detailed_command_telemetry;
3838

3939
explicit LLDBConfig(bool enable_telemetry, bool detailed_command_telemetry)
4040
: ::llvm::telemetry::Config(enable_telemetry),
@@ -81,23 +81,25 @@ struct LLDBBaseTelemetryInfo : public llvm::telemetry::TelemetryInfo {
8181
};
8282

8383
struct CommandInfo : public LLDBBaseTelemetryInfo {
84-
// If the command is/can be associated with a target entry this field contains
85-
// that target's UUID. <EMPTY> otherwise.
84+
/// If the command is/can be associated with a target entry this field
85+
/// contains that target's UUID. <EMPTY> otherwise.
8686
UUID target_uuid;
87-
// A unique ID for a command so the manager can match the start entry with
88-
// its end entry. These values only need to be unique within the same session.
89-
// Necessary because we'd send off an entry right before a command's execution
90-
// and another right after. This is to avoid losing telemetry if the command
91-
// does not execute successfully.
87+
/// A unique ID for a command so the manager can match the start entry with
88+
/// its end entry. These values only need to be unique within the same
89+
/// session. Necessary because we'd send off an entry right before a command's
90+
/// execution and another right after. This is to avoid losing telemetry if
91+
/// the command does not execute successfully.
9292
uint64_t command_id;
93-
// Eg., "breakpoint set"
93+
/// The command name(eg., "breakpoint set")
9494
std::string command_name;
95-
// !!NOTE!! These two fields are not collected by default due to PII risks.
96-
// Vendor may allow them by setting the
97-
// LLDBConfig::m_detailed_command_telemetry.
95+
/// These two fields are not collected by default due to PII risks.
96+
/// Vendor may allow them by setting the
97+
/// LLDBConfig::detailed_command_telemetry.
98+
/// @{
9899
std::string original_command;
99100
std::string args;
100-
// Return status of a command and any error description in case of error.
101+
/// @}
102+
/// Return status of a command and any error description in case of error.
101103
std::optional<lldb::ReturnStatus> ret_status;
102104
std::optional<std::string> error_data;
103105

lldb/source/Interpreter/CommandInterpreter.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1890,7 +1890,7 @@ bool CommandInterpreter::HandleCommand(const char *command_line,
18901890
const bool detailed_command_telemetry =
18911891
telemetry::TelemetryManager::GetInstance()
18921892
->GetConfig()
1893-
->m_detailed_command_telemetry;
1893+
->detailed_command_telemetry;
18941894
const int command_id = telemetry::CommandInfo::GetNextId();
18951895

18961896
std::string command_string(command_line);

0 commit comments

Comments
 (0)