llvm-project/lldb/source/Commands/CommandObjectApropos.h
Pete Lawrence 92d8a28cc6
[lldb] Part 2 of 2 - Refactor CommandObject::DoExecute(...) return void (not bool) (#69991)
[lldb] Part 2 of 2 - Refactor `CommandObject::DoExecute(...)` to return
`void` instead of ~~`bool`~~

Justifications:
- The code doesn't ultimately apply the `true`/`false` return values.
- The methods already pass around a `CommandReturnObject`, typically
with a `result` parameter.
- Each command return object already contains:
	- A more precise status
	- The error code(s) that apply to that status

Part 1 refactors the `CommandObject::Execute(...)` method.
- See
[https://github.com/llvm/llvm-project/pull/69989](https://github.com/llvm/llvm-project/pull/69989)

rdar://117378957
2023-10-30 13:21:00 -07:00

32 lines
904 B
C++

//===-- CommandObjectApropos.h -----------------------------------*- C++
//-*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===----------------------------------------------------------------------===//
#ifndef LLDB_SOURCE_COMMANDS_COMMANDOBJECTAPROPOS_H
#define LLDB_SOURCE_COMMANDS_COMMANDOBJECTAPROPOS_H
#include "lldb/Interpreter/CommandObject.h"
namespace lldb_private {
// CommandObjectApropos
class CommandObjectApropos : public CommandObjectParsed {
public:
CommandObjectApropos(CommandInterpreter &interpreter);
~CommandObjectApropos() override;
protected:
void DoExecute(Args &command, CommandReturnObject &result) override;
};
} // namespace lldb_private
#endif // LLDB_SOURCE_COMMANDS_COMMANDOBJECTAPROPOS_H