1 //===-- CommandObjectQuit.cpp -----------------------------------*- C++ -*-===//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 
10 #include "lldb/lldb-python.h"
11 
12 #include "CommandObjectQuit.h"
13 
14 // C Includes
15 // C++ Includes
16 // Other libraries and framework includes
17 // Project includes
18 #include "lldb/Interpreter/CommandInterpreter.h"
19 #include "lldb/Interpreter/CommandReturnObject.h"
20 
21 using namespace lldb;
22 using namespace lldb_private;
23 
24 //-------------------------------------------------------------------------
25 // CommandObjectQuit
26 //-------------------------------------------------------------------------
27 
28 CommandObjectQuit::CommandObjectQuit (CommandInterpreter &interpreter) :
29     CommandObjectParsed (interpreter, "quit", "Quit out of the LLDB debugger.", "quit")
30 {
31 }
32 
33 CommandObjectQuit::~CommandObjectQuit ()
34 {
35 }
36 
37 bool
38 CommandObjectQuit::DoExecute (Args& command, CommandReturnObject &result)
39 {
40     m_interpreter.BroadcastEvent (CommandInterpreter::eBroadcastBitQuitCommandReceived);
41     result.SetStatus (eReturnStatusQuit);
42     return true;
43 }
44 
45