blob: 79632971b3f47af1c12472ced78d0093282b9340 [file] [log] [blame]
Chris Lattner24943d22010-06-08 16:52:24 +00001//===-- 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 "CommandObjectQuit.h"
11
12// C Includes
13// C++ Includes
14// Other libraries and framework includes
15// Project includes
Eli Friedmanb4a47282010-06-09 07:57:51 +000016#include "lldb/Interpreter/CommandInterpreter.h"
17#include "lldb/Interpreter/CommandReturnObject.h"
Chris Lattner24943d22010-06-08 16:52:24 +000018
19using namespace lldb;
20using namespace lldb_private;
21
22//-------------------------------------------------------------------------
23// CommandObjectQuit
24//-------------------------------------------------------------------------
25
Greg Clayton238c0a12010-09-18 01:14:36 +000026CommandObjectQuit::CommandObjectQuit (CommandInterpreter &interpreter) :
Jim Inghamda26bd22012-06-08 21:56:10 +000027 CommandObjectParsed (interpreter, "quit", "Quit out of the LLDB debugger.", "quit")
Chris Lattner24943d22010-06-08 16:52:24 +000028{
29}
30
31CommandObjectQuit::~CommandObjectQuit ()
32{
33}
34
35bool
Jim Inghamda26bd22012-06-08 21:56:10 +000036CommandObjectQuit::DoExecute (Args& command, CommandReturnObject &result)
Chris Lattner24943d22010-06-08 16:52:24 +000037{
Greg Clayton238c0a12010-09-18 01:14:36 +000038 m_interpreter.BroadcastEvent (CommandInterpreter::eBroadcastBitQuitCommandReceived);
Chris Lattner24943d22010-06-08 16:52:24 +000039 result.SetStatus (eReturnStatusQuit);
40 return true;
41}
42