diff options
Diffstat (limited to 'tools/lldb-mi')
150 files changed, 511 insertions, 1869 deletions
diff --git a/tools/lldb-mi/MICmdArgContext.cpp b/tools/lldb-mi/MICmdArgContext.cpp index 57f682bea22a..18da5b5d67a3 100644 --- a/tools/lldb-mi/MICmdArgContext.cpp +++ b/tools/lldb-mi/MICmdArgContext.cpp @@ -1,9 +1,8 @@ //===-- MICmdArgContext.cpp -------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -11,7 +10,6 @@ #include "MICmdArgContext.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgContext constructor. // Type: Method. // Args: None. @@ -21,7 +19,6 @@ CMICmdArgContext::CMICmdArgContext() {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgContext constructor. // Type: Method. // Args: vrCmdLineArgsRaw - (R) The text description of the arguments @@ -33,7 +30,6 @@ CMICmdArgContext::CMICmdArgContext(const CMIUtilString &vrCmdLineArgsRaw) : m_strCmdArgsAndOptions(vrCmdLineArgsRaw) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgContext destructor. // Type: Method. // Args: None. @@ -43,7 +39,6 @@ CMICmdArgContext::CMICmdArgContext(const CMIUtilString &vrCmdLineArgsRaw) CMICmdArgContext::~CMICmdArgContext() {} //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the remainder of the command's argument options left to // parse. // Type: Method. @@ -56,7 +51,6 @@ const CMIUtilString &CMICmdArgContext::GetArgsLeftToParse() const { } //++ -//------------------------------------------------------------------------------------ // Details: Ask if this arguments string has any arguments. // Type: Method. // Args: None. @@ -69,7 +63,6 @@ bool CMICmdArgContext::IsEmpty() const { } //++ -//------------------------------------------------------------------------------------ // Details: Remove the argument from the options text and any space after the // argument // if applicable. @@ -128,7 +121,6 @@ bool CMICmdArgContext::RemoveArg(const CMIUtilString &vArg) { } //++ -//------------------------------------------------------------------------------------ // Details: Remove the argument at the Nth word position along in the context // string. // Any space after the argument is removed if applicable. A search is @@ -188,7 +180,6 @@ bool CMICmdArgContext::RemoveArgAtPos(const CMIUtilString &vArg, } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve number of arguments or options present in the command's // option text. // Type: Method. @@ -202,7 +193,6 @@ size_t CMICmdArgContext::GetNumberArgsPresent() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve all the arguments or options remaining in *this context. // Type: Method. // Args: None. @@ -216,7 +206,6 @@ CMIUtilString::VecString_t CMICmdArgContext::GetArgs() const { } //++ -//------------------------------------------------------------------------------------ // Details: Copy assignment operator. // Type: Method. // Args: vOther - (R) The variable to copy from. diff --git a/tools/lldb-mi/MICmdArgContext.h b/tools/lldb-mi/MICmdArgContext.h index ed4f377d2fbe..801d2d90cdc5 100644 --- a/tools/lldb-mi/MICmdArgContext.h +++ b/tools/lldb-mi/MICmdArgContext.h @@ -1,9 +1,8 @@ //===-- MICmdArgContext.h ---------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdArgSet.cpp b/tools/lldb-mi/MICmdArgSet.cpp index ca942148908e..0d67c03bfeae 100644 --- a/tools/lldb-mi/MICmdArgSet.cpp +++ b/tools/lldb-mi/MICmdArgSet.cpp @@ -1,9 +1,8 @@ //===-- MICmdArgSet.cpp -----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -14,7 +13,6 @@ #include "MICmnResources.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgSet constructor. // Type: Method. // Args: None. @@ -25,7 +23,6 @@ CMICmdArgSet::CMICmdArgSet() : m_bIsArgsPresentButNotHandledByCmd(false), m_constStrCommaSpc(", ") {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgSet destructor. // Type: Method. // Args: None. @@ -38,7 +35,6 @@ CMICmdArgSet::~CMICmdArgSet() { } //++ -//------------------------------------------------------------------------------------ // Details: Release resources used by *this container object. // Type: Method. // Args: None. @@ -67,7 +63,6 @@ void CMICmdArgSet::Destroy() { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the state flag indicating that the command set up ready to // parse // command arguments or options found that one or more arguments was @@ -84,7 +79,6 @@ bool CMICmdArgSet::IsArgsPresentButNotHandledByCmd() const { } //++ -//------------------------------------------------------------------------------------ // Details: Add the list of command's arguments to parse and validate another // one. // Type: Method. @@ -95,7 +89,6 @@ bool CMICmdArgSet::IsArgsPresentButNotHandledByCmd() const { void CMICmdArgSet::Add(CMICmdArgValBase *vArg) { m_setCmdArgs.push_back(vArg); } //++ -//------------------------------------------------------------------------------------ // Details: After validating an options line of text (the context) and there is // a failure, // it is likely a mandatory command argument that is required is @@ -111,7 +104,6 @@ const CMICmdArgSet::SetCmdArgs_t &CMICmdArgSet::GetArgsThatAreMissing() const { } //++ -//------------------------------------------------------------------------------------ // Details: After validating an options line of text (the context) and there is // a failure, // it may be because one or more arguments were unable to extract a @@ -127,7 +119,6 @@ const CMICmdArgSet::SetCmdArgs_t &CMICmdArgSet::GetArgsThatInvalid() const { } //++ -//------------------------------------------------------------------------------------ // Details: The list of argument or option (objects) that were specified by the // command // and so recognised when parsed but were not handled. Ideally the @@ -149,7 +140,6 @@ const CMICmdArgSet::SetCmdArgs_t &CMICmdArgSet::GetArgsNotHandledByCmd() const { } //++ -//------------------------------------------------------------------------------------ // Details: Given a set of command argument objects parse the context option // string to // find those argument and retrieve their value. If the function fails @@ -200,7 +190,6 @@ bool CMICmdArgSet::Validate(const CMIUtilString &vStrMiCmd, } //++ -//------------------------------------------------------------------------------------ // Details: Having validated the command's options text and failed for some // reason form // the error message made up with the faults found. @@ -311,7 +300,6 @@ bool CMICmdArgSet::ValidationFormErrorMessages( } //++ -//------------------------------------------------------------------------------------ // Details: Ask if the command's argument options text had any arguments. // Type: Method. // Args: None. @@ -324,7 +312,6 @@ bool CMICmdArgSet::IsArgContextEmpty() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the number of arguments that are being used for the // command. // Type: Method. @@ -335,7 +322,6 @@ bool CMICmdArgSet::IsArgContextEmpty() const { size_t CMICmdArgSet::GetCount() const { return m_setCmdArgs.size(); } //++ -//------------------------------------------------------------------------------------ // Details: Given a set of command argument objects retrieve the argument with // the // specified name. @@ -365,7 +351,6 @@ bool CMICmdArgSet::GetArg(const CMIUtilString &vArgName, } //++ -//------------------------------------------------------------------------------------ // Details: Write a warning message to the MI Log file about the command's // arguments or // options that were found present but not handled. diff --git a/tools/lldb-mi/MICmdArgSet.h b/tools/lldb-mi/MICmdArgSet.h index 88716a91f0ad..4df5aaf51567 100644 --- a/tools/lldb-mi/MICmdArgSet.h +++ b/tools/lldb-mi/MICmdArgSet.h @@ -1,9 +1,8 @@ //===-- MICmdArgSet.h -------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdArgValBase.cpp b/tools/lldb-mi/MICmdArgValBase.cpp index 8b1706db93ef..dc9c7e0257e7 100644 --- a/tools/lldb-mi/MICmdArgValBase.cpp +++ b/tools/lldb-mi/MICmdArgValBase.cpp @@ -1,9 +1,8 @@ //===-- MICmdArgValBase.cpp -------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -12,7 +11,6 @@ #include "MIUtilString.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValBase constructor. // Type: Method. // Args: None. @@ -24,7 +22,6 @@ CMICmdArgValBase::CMICmdArgValBase() m_bIsMissingOptions(false) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValBase constructor. // Type: Method. // Args: vrArgName - (R) Argument's name to search by. @@ -43,7 +40,6 @@ CMICmdArgValBase::CMICmdArgValBase(const CMIUtilString &vrArgName, m_bIsMissingOptions(false) {} //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the state flag of whether the argument is handled by the // command or // not. @@ -58,7 +54,6 @@ bool CMICmdArgValBase::GetIsMissingOptions() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the state flag of whether the argument is handled by the // command or // not. @@ -71,7 +66,6 @@ bool CMICmdArgValBase::GetIsMissingOptions() const { bool CMICmdArgValBase::GetIsHandledByCmd() const { return m_bHandled; } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the name of *this argument. // Type: Method. // Args: None. @@ -81,7 +75,6 @@ bool CMICmdArgValBase::GetIsHandledByCmd() const { return m_bHandled; } const CMIUtilString &CMICmdArgValBase::GetName() const { return m_strArgName; } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the state flag of whether the argument was found in the // command's // argument / options string. @@ -94,7 +87,6 @@ const CMIUtilString &CMICmdArgValBase::GetName() const { return m_strArgName; } bool CMICmdArgValBase::GetFound() const { return m_bFound; } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the state flag indicating whether the value was obtained // from the // text arguments string and is valid. @@ -107,7 +99,6 @@ bool CMICmdArgValBase::GetFound() const { return m_bFound; } bool CMICmdArgValBase::GetValid() const { return m_bValid; } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the state flag indicating whether *this argument is a // mandatory // argument for the command or is optional to be present. @@ -120,7 +111,6 @@ bool CMICmdArgValBase::GetValid() const { return m_bValid; } bool CMICmdArgValBase::GetIsMandatory() const { return m_bMandatory; } //++ -//------------------------------------------------------------------------------------ // Details: Parse the command's argument options string and try to extract the // value *this // argument is looking for. diff --git a/tools/lldb-mi/MICmdArgValBase.h b/tools/lldb-mi/MICmdArgValBase.h index 1b4582963e57..feb7fe4f04d3 100644 --- a/tools/lldb-mi/MICmdArgValBase.h +++ b/tools/lldb-mi/MICmdArgValBase.h @@ -1,9 +1,8 @@ //===-- MICmdArgValBase.h ---------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -86,7 +85,6 @@ protected: }; //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValBaseTemplate constructor. // Type: Method. // Args: vrArgName - (R) Argument's name to search by. @@ -104,7 +102,6 @@ CMICmdArgValBaseTemplate<T>::CMICmdArgValBaseTemplate( : CMICmdArgValBase(vrArgName, vbMandatory, vbHandleByCmd) {} //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the value the argument parsed from the command's argument / // options // text string. diff --git a/tools/lldb-mi/MICmdArgValConsume.cpp b/tools/lldb-mi/MICmdArgValConsume.cpp index 86c4f0912565..01d001366596 100644 --- a/tools/lldb-mi/MICmdArgValConsume.cpp +++ b/tools/lldb-mi/MICmdArgValConsume.cpp @@ -1,9 +1,8 @@ //===-- MICmdArgValConsume.cpp ----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -12,7 +11,6 @@ #include "MICmdArgContext.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValConsume constructor. // Type: Method. // Args: None. @@ -22,7 +20,6 @@ CMICmdArgValConsume::CMICmdArgValConsume() {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValConsume constructor. // Type: Method. // Args: vrArgName - (R) Argument's name to search by. @@ -36,7 +33,6 @@ CMICmdArgValConsume::CMICmdArgValConsume(const CMIUtilString &vrArgName, : CMICmdArgValBaseTemplate(vrArgName, vbMandatory, true) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValConsume destructor. // Type: Overidden. // Args: None. @@ -46,7 +42,6 @@ CMICmdArgValConsume::CMICmdArgValConsume(const CMIUtilString &vrArgName, CMICmdArgValConsume::~CMICmdArgValConsume() {} //++ -//------------------------------------------------------------------------------------ // Details: Parse the command's argument options string and try to extract the // value *this // argument is looking for. @@ -82,7 +77,6 @@ bool CMICmdArgValConsume::Validate(CMICmdArgContext &vwArgContext) { } //++ -//------------------------------------------------------------------------------------ // Details: Nothing to examine as we just want to consume the argument or option // (ignore // it). diff --git a/tools/lldb-mi/MICmdArgValConsume.h b/tools/lldb-mi/MICmdArgValConsume.h index 1169eb9a4efe..62207f04b679 100644 --- a/tools/lldb-mi/MICmdArgValConsume.h +++ b/tools/lldb-mi/MICmdArgValConsume.h @@ -1,9 +1,8 @@ //===-- MICmdArgValConsume.h ------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdArgValFile.cpp b/tools/lldb-mi/MICmdArgValFile.cpp index cb2ba0125903..7171b0fa8f18 100644 --- a/tools/lldb-mi/MICmdArgValFile.cpp +++ b/tools/lldb-mi/MICmdArgValFile.cpp @@ -1,9 +1,8 @@ //===-- MICmdArgValFile.cpp -------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -12,7 +11,6 @@ #include "MICmdArgContext.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValFile constructor. // Type: Method. // Args: None. @@ -22,7 +20,6 @@ CMICmdArgValFile::CMICmdArgValFile() {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValFile constructor. // Type: Method. // Args: vrArgName - (R) Argument's name to search by. @@ -39,7 +36,6 @@ CMICmdArgValFile::CMICmdArgValFile(const CMIUtilString &vrArgName, : CMICmdArgValBaseTemplate(vrArgName, vbMandatory, vbHandleByCmd) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValFile destructor. // Type: Overridden. // Args: None. @@ -49,7 +45,6 @@ CMICmdArgValFile::CMICmdArgValFile(const CMIUtilString &vrArgName, CMICmdArgValFile::~CMICmdArgValFile() {} //++ -//------------------------------------------------------------------------------------ // Details: Parse the command's argument options string and try to extract the // value *this // argument is looking for. @@ -102,7 +97,6 @@ bool CMICmdArgValFile::Validate(CMICmdArgContext &vwArgContext) { } //++ -//------------------------------------------------------------------------------------ // Details: Given some text extract the file name path from it. If a space is // found in // path done return the path surrounded in quotes. @@ -125,7 +119,6 @@ CMICmdArgValFile::GetFileNamePath(const CMIUtilString &vrTxt) const { } //++ -//------------------------------------------------------------------------------------ // Details: Examine the string and determine if it is a valid file name path. // Type: Method. // Args: vrFileNamePath - (R) File's name and directory path. @@ -162,7 +155,6 @@ bool CMICmdArgValFile::IsFilePath(const CMIUtilString &vrFileNamePath) const { } //++ -//------------------------------------------------------------------------------------ // Details: Determine if the path contains valid characters for a file path. // Letters can be // either upper or lower case. diff --git a/tools/lldb-mi/MICmdArgValFile.h b/tools/lldb-mi/MICmdArgValFile.h index def870e76493..8030cb783aab 100644 --- a/tools/lldb-mi/MICmdArgValFile.h +++ b/tools/lldb-mi/MICmdArgValFile.h @@ -1,9 +1,8 @@ //===-- MICmdArgValFile.h ---------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdArgValListBase.cpp b/tools/lldb-mi/MICmdArgValListBase.cpp index ff18abaac38c..bd175f3afe64 100644 --- a/tools/lldb-mi/MICmdArgValListBase.cpp +++ b/tools/lldb-mi/MICmdArgValListBase.cpp @@ -1,9 +1,8 @@ //===-- MICmdArgValListBase.cpp ---------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -19,7 +18,6 @@ #include "MICmdArgValThreadGrp.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValListBase constructor. // Type: Method. // Args: None. @@ -30,7 +28,6 @@ CMICmdArgValListBase::CMICmdArgValListBase() : m_eArgType(eArgValType_invalid) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValListBase constructor. // Type: Method. // Args: vrArgName - (R) Argument's name to search by. @@ -48,7 +45,6 @@ CMICmdArgValListBase::CMICmdArgValListBase(const CMIUtilString &vrArgName, m_eArgType(eArgValType_invalid) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValListBase constructor. // Type: Method. // Args: vrArgName - (R) Argument's name to search by. @@ -69,7 +65,6 @@ CMICmdArgValListBase::CMICmdArgValListBase(const CMIUtilString &vrArgName, m_eArgType(veType) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValListBase destructor. // Type: Overridden. // Args: None. @@ -82,7 +77,6 @@ CMICmdArgValListBase::~CMICmdArgValListBase() { } //++ -//------------------------------------------------------------------------------------ // Details: Tear down resources used by *this object. // Type: Method. // Args: None. @@ -103,7 +97,6 @@ void CMICmdArgValListBase::Destroy() { } //++ -//------------------------------------------------------------------------------------ // Details: Create an CMICmdArgValBase derived object matching the type // specified // and put the option or argument's value inside it. @@ -164,7 +157,6 @@ CMICmdArgValListBase::CreationObj(const CMIUtilString &vrTxt, } //++ -//------------------------------------------------------------------------------------ // Details: Validate the option or argument is the correct type. // Type: Method. // Args: vrTxt - (R) Text version the option or argument. diff --git a/tools/lldb-mi/MICmdArgValListBase.h b/tools/lldb-mi/MICmdArgValListBase.h index 03cef723e2e0..4437ae19a87c 100644 --- a/tools/lldb-mi/MICmdArgValListBase.h +++ b/tools/lldb-mi/MICmdArgValListBase.h @@ -1,9 +1,8 @@ //===-- MICmdArgValListBase.h -----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -46,7 +45,6 @@ public: // Enums: public: //++ - //--------------------------------------------------------------------------------- // Details: CMICmdArgValListBase needs to know what type of argument to look // for in // the command options text. It also needs to create argument objects diff --git a/tools/lldb-mi/MICmdArgValListOfN.cpp b/tools/lldb-mi/MICmdArgValListOfN.cpp index 103008e98816..b53424543b2b 100644 --- a/tools/lldb-mi/MICmdArgValListOfN.cpp +++ b/tools/lldb-mi/MICmdArgValListOfN.cpp @@ -1,9 +1,8 @@ //===-- MICmdArgValListOfN.cpp ----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -18,7 +17,6 @@ #include "MICmdArgValThreadGrp.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValListOfN constructor. // Type: Method. // Args: None. @@ -28,7 +26,6 @@ CMICmdArgValListOfN::CMICmdArgValListOfN() {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValListOfN constructor. // Type: Method. // Args: vrArgName - (R) Argument's name to search by. @@ -48,7 +45,6 @@ CMICmdArgValListOfN::CMICmdArgValListOfN(const CMIUtilString &vrArgName, : CMICmdArgValListBase(vrArgName, vbMandatory, vbHandleByCmd, veType) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValListOfN destructor. // Type: Overridden. // Args: None. @@ -58,7 +54,6 @@ CMICmdArgValListOfN::CMICmdArgValListOfN(const CMIUtilString &vrArgName, CMICmdArgValListOfN::~CMICmdArgValListOfN() {} //++ -//------------------------------------------------------------------------------------ // Details: Parse the command's argument options string and try to extract the // list of // arguments based on the argument object type to look for. @@ -88,7 +83,6 @@ bool CMICmdArgValListOfN::Validate(CMICmdArgContext &vwArgContext) { } //++ -//------------------------------------------------------------------------------------ // Details: Create list of argument objects each holding a value extract from // the command // options line. @@ -125,7 +119,6 @@ bool CMICmdArgValListOfN::CreateList(const CMIUtilString &vrTxt) { } //++ -//------------------------------------------------------------------------------------ // Details: Examine the string and determine if it is a valid string type // argument. // Type: Method. @@ -158,7 +151,6 @@ bool CMICmdArgValListOfN::IsListOfN(const CMIUtilString &vrTxt) const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the list of CMICmdArgValBase derived option objects found // following // *this long option argument. For example "list-thread-groups [ diff --git a/tools/lldb-mi/MICmdArgValListOfN.h b/tools/lldb-mi/MICmdArgValListOfN.h index 002970841672..74e8c16f7d6e 100644 --- a/tools/lldb-mi/MICmdArgValListOfN.h +++ b/tools/lldb-mi/MICmdArgValListOfN.h @@ -1,9 +1,8 @@ //===-- MICmdArgValListOfN.h ------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -62,7 +61,6 @@ private: }; //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the first argument or option value from the list of 1 or // more options // parsed from the command's options string. diff --git a/tools/lldb-mi/MICmdArgValNumber.cpp b/tools/lldb-mi/MICmdArgValNumber.cpp index 6ef6769391ec..ad2df79bf3d9 100644 --- a/tools/lldb-mi/MICmdArgValNumber.cpp +++ b/tools/lldb-mi/MICmdArgValNumber.cpp @@ -1,9 +1,8 @@ //===-- MICmdArgValNumber.cpp -----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -12,7 +11,6 @@ #include "MICmdArgContext.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValNumber constructor. // Type: Method. // Args: None. @@ -24,7 +22,6 @@ CMICmdArgValNumber::CMICmdArgValNumber() m_nNumber(0) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValNumber constructor. // Type: Method. // Args: vrArgName - (R) Argument's name to search by. @@ -46,7 +43,6 @@ CMICmdArgValNumber::CMICmdArgValNumber( m_nNumberFormatMask(vnNumberFormatMask), m_nNumber(0) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValNumber destructor. // Type: Overridden. // Args: None. @@ -56,7 +52,6 @@ CMICmdArgValNumber::CMICmdArgValNumber( CMICmdArgValNumber::~CMICmdArgValNumber() {} //++ -//------------------------------------------------------------------------------------ // Details: Parse the command's argument options string and try to extract the // value *this // argument is looking for. @@ -106,7 +101,6 @@ bool CMICmdArgValNumber::Validate(CMICmdArgContext &vwArgContext) { } //++ -//------------------------------------------------------------------------------------ // Details: Examine the string and determine if it is a valid string type // argument. // Type: Method. @@ -135,7 +129,6 @@ bool CMICmdArgValNumber::IsArgNumber(const CMIUtilString &vrTxt) const { } //++ -//------------------------------------------------------------------------------------ // Details: Extract the thread group number from the thread group argument. // Type: Method. // Args: vrTxt - (R) Some text. @@ -154,7 +147,6 @@ bool CMICmdArgValNumber::ExtractNumber(const CMIUtilString &vrTxt) { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the thread group ID found in the argument. // Type: Method. // Args: None. diff --git a/tools/lldb-mi/MICmdArgValNumber.h b/tools/lldb-mi/MICmdArgValNumber.h index 5f94fc86893f..23c888e5d806 100644 --- a/tools/lldb-mi/MICmdArgValNumber.h +++ b/tools/lldb-mi/MICmdArgValNumber.h @@ -1,9 +1,8 @@ //===-- MICmdArgValNumber.h -------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -29,7 +28,6 @@ class CMICmdArgValNumber : public CMICmdArgValBaseTemplate<MIint64> { // Enums: public: //++ - //--------------------------------------------------------------------------------- // Details: CMICmdArgValNumber needs to know what format of argument to look // for in // the command options text. diff --git a/tools/lldb-mi/MICmdArgValOptionLong.cpp b/tools/lldb-mi/MICmdArgValOptionLong.cpp index 3824fe19188a..3dc9d40f4b56 100644 --- a/tools/lldb-mi/MICmdArgValOptionLong.cpp +++ b/tools/lldb-mi/MICmdArgValOptionLong.cpp @@ -1,9 +1,8 @@ //===-- MICmdArgValOptionLong.cpp -------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -12,7 +11,6 @@ #include "MICmdArgContext.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValOptionLong constructor. // Type: Method. // Args: None. @@ -23,7 +21,6 @@ CMICmdArgValOptionLong::CMICmdArgValOptionLong() : m_nExpectingNOptions(0), m_eExpectingOptionType(eArgValType_invalid) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValOptionLong constructor. // Type: Method. // Args: vrArgName - (R) Argument's name to search by. @@ -41,7 +38,6 @@ CMICmdArgValOptionLong::CMICmdArgValOptionLong(const CMIUtilString &vrArgName, m_nExpectingNOptions(0), m_eExpectingOptionType(eArgValType_invalid) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValOptionLong constructor. // Type: Method. // Args: vrArgName - (R) Argument's name to search by. @@ -66,7 +62,6 @@ CMICmdArgValOptionLong::CMICmdArgValOptionLong(const CMIUtilString &vrArgName, m_eExpectingOptionType(veType) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValOptionLong destructor. // Type: Overridden. // Args: None. @@ -79,7 +74,6 @@ CMICmdArgValOptionLong::~CMICmdArgValOptionLong() { } //++ -//------------------------------------------------------------------------------------ // Details: Tear down resources used by *this object. // Type: Method. // Args: None. @@ -100,7 +94,6 @@ void CMICmdArgValOptionLong::Destroy() { } //++ -//------------------------------------------------------------------------------------ // Details: Parse the command's argument options string and try to extract the // long // argument *this argument type is looking for. @@ -168,7 +161,6 @@ bool CMICmdArgValOptionLong::Validate(CMICmdArgContext &vwArgContext) { } //++ -//------------------------------------------------------------------------------------ // Details: Parse the text following *this argument and extract the options the // values of // CMICmdArgValListBase::m_eArgType forming argument objects for each @@ -229,7 +221,6 @@ bool CMICmdArgValOptionLong::ExtractExpectedOptions(CMICmdArgContext &vrwTxt, } //++ -//------------------------------------------------------------------------------------ // Details: Examine the string and determine if it is a valid long type option // argument. // Long type argument looks like --someLongOption. @@ -256,7 +247,6 @@ bool CMICmdArgValOptionLong::IsArgLongOption(const CMIUtilString &vrTxt) const { } //++ -//------------------------------------------------------------------------------------ // Details: Examine the string and determine if it is a valid long type option // argument. // Long type argument looks like --someLongOption. @@ -271,7 +261,6 @@ bool CMICmdArgValOptionLong::IsArgOptionCorrect( } //++ -//------------------------------------------------------------------------------------ // Details: Does the argument name of the argument being parsed ATM match the // name of // *this argument object. @@ -286,7 +275,6 @@ bool CMICmdArgValOptionLong::ArgNameMatch(const CMIUtilString &vrTxt) const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the list of CMICmdArgValBase derived option objects found // following // *this long option argument. For example "list-thread-groups [ diff --git a/tools/lldb-mi/MICmdArgValOptionLong.h b/tools/lldb-mi/MICmdArgValOptionLong.h index cabe3799de86..240829733680 100644 --- a/tools/lldb-mi/MICmdArgValOptionLong.h +++ b/tools/lldb-mi/MICmdArgValOptionLong.h @@ -1,9 +1,8 @@ //===-- MICmdArgValOptionLong.h ---------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -79,7 +78,6 @@ private: }; //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the first argument or option value from the list of 1 or // more options // parsed from the command's options string. diff --git a/tools/lldb-mi/MICmdArgValOptionShort.cpp b/tools/lldb-mi/MICmdArgValOptionShort.cpp index cd403aa8fd43..7b7116cd5f18 100644 --- a/tools/lldb-mi/MICmdArgValOptionShort.cpp +++ b/tools/lldb-mi/MICmdArgValOptionShort.cpp @@ -1,9 +1,8 @@ //===-- MICmdArgValOptionShort.cpp ------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -12,7 +11,6 @@ #include "MICmdArgContext.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValOptionShort constructor. // Type: Method. // Args: None. @@ -22,7 +20,6 @@ CMICmdArgValOptionShort::CMICmdArgValOptionShort() {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValOptionShort constructor. // Type: Method. // Args: vrArgName - (R) Argument's name to search by. @@ -39,7 +36,6 @@ CMICmdArgValOptionShort::CMICmdArgValOptionShort(const CMIUtilString &vrArgName, : CMICmdArgValOptionLong(vrArgName, vbMandatory, vbHandleByCmd) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValOptionLong constructor. // Type: Method. // Args: vrArgName - (R) Argument's name to search by. @@ -62,7 +58,6 @@ CMICmdArgValOptionShort::CMICmdArgValOptionShort( vnExpectingNOptions) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValOptionShort destructor. // Type: Overridden. // Args: None. @@ -72,7 +67,6 @@ CMICmdArgValOptionShort::CMICmdArgValOptionShort( CMICmdArgValOptionShort::~CMICmdArgValOptionShort() {} //++ -//------------------------------------------------------------------------------------ // Details: Examine the string and determine if it is a valid short type option // argument. // Type: Method. @@ -99,7 +93,6 @@ bool CMICmdArgValOptionShort::IsArgShortOption( } //++ -//------------------------------------------------------------------------------------ // Details: Examine the string and determine if it is a valid short type option // argument. // Long type argument looks like -f some short option. @@ -114,7 +107,6 @@ bool CMICmdArgValOptionShort::IsArgOptionCorrect( } //++ -//------------------------------------------------------------------------------------ // Details: Does the argument name of the argument being parsed ATM match the // name of // *this argument object. diff --git a/tools/lldb-mi/MICmdArgValOptionShort.h b/tools/lldb-mi/MICmdArgValOptionShort.h index 09482899a300..fd39c9e73a57 100644 --- a/tools/lldb-mi/MICmdArgValOptionShort.h +++ b/tools/lldb-mi/MICmdArgValOptionShort.h @@ -1,9 +1,8 @@ //===-- MICmdArgValOptionShort.h --------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdArgValPrintValues.cpp b/tools/lldb-mi/MICmdArgValPrintValues.cpp index 722c4c258313..a2ce45247375 100644 --- a/tools/lldb-mi/MICmdArgValPrintValues.cpp +++ b/tools/lldb-mi/MICmdArgValPrintValues.cpp @@ -1,9 +1,8 @@ //===-- MICmdArgValPrintValues.cpp ------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -12,7 +11,6 @@ #include "MICmdArgContext.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValPrintValues constructor. // Type: Method. // Args: None. @@ -22,7 +20,6 @@ CMICmdArgValPrintValues::CMICmdArgValPrintValues() : m_nPrintValues(0) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValPrintValues constructor. // Type: Method. // Args: vrArgName - (R) Argument's name to search by. @@ -40,7 +37,6 @@ CMICmdArgValPrintValues::CMICmdArgValPrintValues(const CMIUtilString &vrArgName, m_nPrintValues(0) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValPrintValues destructor. // Type: Overridden. // Args: None. @@ -50,7 +46,6 @@ CMICmdArgValPrintValues::CMICmdArgValPrintValues(const CMIUtilString &vrArgName, CMICmdArgValPrintValues::~CMICmdArgValPrintValues() {} //++ -//------------------------------------------------------------------------------------ // Details: Parse the command's argument options string and try to extract the // value *this // argument is looking for. @@ -77,7 +72,6 @@ bool CMICmdArgValPrintValues::Validate(CMICmdArgContext &vwArgContext) { } //++ -//------------------------------------------------------------------------------------ // Details: Examine the string and determine if it is a valid string type // argument. // Type: Method. @@ -96,7 +90,6 @@ bool CMICmdArgValPrintValues::IsArgPrintValues( } //++ -//------------------------------------------------------------------------------------ // Details: Extract the print-values from the print-values argument. // Type: Method. // Args: vrTxt - (R) Some text. @@ -121,7 +114,6 @@ bool CMICmdArgValPrintValues::ExtractPrintValues(const CMIUtilString &vrTxt) { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the print-values found in the argument. // Type: Method. // Args: None. diff --git a/tools/lldb-mi/MICmdArgValPrintValues.h b/tools/lldb-mi/MICmdArgValPrintValues.h index ddfa7c24fcc1..3fa8142c1ae5 100644 --- a/tools/lldb-mi/MICmdArgValPrintValues.h +++ b/tools/lldb-mi/MICmdArgValPrintValues.h @@ -1,9 +1,8 @@ //===-- MICmdArgValPrintValues.h --------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdArgValString.cpp b/tools/lldb-mi/MICmdArgValString.cpp index 28d4d18c361b..bd105bc289b3 100644 --- a/tools/lldb-mi/MICmdArgValString.cpp +++ b/tools/lldb-mi/MICmdArgValString.cpp @@ -1,9 +1,8 @@ //===-- MICmdArgValString.cpp -----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -12,7 +11,6 @@ #include "MICmdArgContext.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValString constructor. // Type: Method. // Args: None. @@ -24,7 +22,6 @@ CMICmdArgValString::CMICmdArgValString() m_bHandleDirPaths(false), m_bHandleAnything(false) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValString constructor. // Type: Method. // Args: vbAnything - (R) True = Parse a string and accept anything, false = @@ -37,7 +34,6 @@ CMICmdArgValString::CMICmdArgValString(const bool vbAnything) m_bHandleDirPaths(false), m_bHandleAnything(vbAnything) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValString constructor. // Type: Method. // Args: vbHandleQuotes - (R) True = Parse a string surrounded by quotes @@ -59,7 +55,6 @@ CMICmdArgValString::CMICmdArgValString(const bool vbHandleQuotes, m_bHandleDirPaths(vbHandleDirPaths), m_bHandleAnything(false) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValString constructor. // Type: Method. // Args: vrArgName - (R) Argument's name to search by. @@ -86,7 +81,6 @@ CMICmdArgValString::CMICmdArgValString(const CMIUtilString &vrArgName, m_bHandleDirPaths(false), m_bHandleAnything(false) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValString constructor. // Type: Method. // Args: vrArgName - (R) Argument's name to search by. @@ -116,7 +110,6 @@ CMICmdArgValString::CMICmdArgValString(const CMIUtilString &vrArgName, m_bHandleDirPaths(vbHandleDirPaths), m_bHandleAnything(false) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValString destructor. // Type: Overridden. // Args: None. @@ -126,7 +119,6 @@ CMICmdArgValString::CMICmdArgValString(const CMIUtilString &vrArgName, CMICmdArgValString::~CMICmdArgValString() {} //++ -//------------------------------------------------------------------------------------ // Details: Parse the command's argument options string and try to extract the // value *this // argument is looking for. @@ -147,7 +139,6 @@ bool CMICmdArgValString::Validate(CMICmdArgContext &vrwArgContext) { } //++ -//------------------------------------------------------------------------------------ // Details: Parse the command's argument options string and try to extract only // the next // word delimited by the next space. @@ -181,7 +172,6 @@ bool CMICmdArgValString::ValidateSingleText(CMICmdArgContext &vrwArgContext) { } //++ -//------------------------------------------------------------------------------------ // Details: Parse the command's argument options string and try to extract all // the words // between quotes then delimited by the next space. @@ -213,7 +203,6 @@ bool CMICmdArgValString::ValidateQuotedText(CMICmdArgContext &vrwArgContext) { } //++ -//------------------------------------------------------------------------------------ // Details: Examine the string and determine if it is a valid string type // argument. // Type: Method. @@ -233,7 +222,6 @@ bool CMICmdArgValString::IsStringArg(const CMIUtilString &vrTxt) const { } //++ -//------------------------------------------------------------------------------------ // Details: Examine the string and determine if it is a valid string type // argument or // option value. If the string looks like a long option, short option, @@ -276,7 +264,6 @@ bool CMICmdArgValString::IsStringArgSingleText( } //++ -//------------------------------------------------------------------------------------ // Details: Examine the string and determine if it is a valid string type // argument. // Take into account quotes surrounding the text. Note this function @@ -327,7 +314,6 @@ bool CMICmdArgValString::IsStringArgQuotedText( } //++ -//------------------------------------------------------------------------------------ // Details: Examine the string and determine if it is a valid string type // argument. // Take into account quotes surrounding the text. Take into account @@ -366,7 +352,6 @@ bool CMICmdArgValString::IsStringArgQuotedTextEmbedded( } //++ -//------------------------------------------------------------------------------------ // Details: Examine the string and determine if it is a valid string type // argument. // Take into account quotes surrounding the text. Take into account diff --git a/tools/lldb-mi/MICmdArgValString.h b/tools/lldb-mi/MICmdArgValString.h index e5a6107be507..77041c2d0c9f 100644 --- a/tools/lldb-mi/MICmdArgValString.h +++ b/tools/lldb-mi/MICmdArgValString.h @@ -1,9 +1,8 @@ //===-- MICmdArgValString.h -------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdArgValThreadGrp.cpp b/tools/lldb-mi/MICmdArgValThreadGrp.cpp index 4ed83e6191e1..201d516525fd 100644 --- a/tools/lldb-mi/MICmdArgValThreadGrp.cpp +++ b/tools/lldb-mi/MICmdArgValThreadGrp.cpp @@ -1,9 +1,8 @@ //===-- MICmdArgValThreadGrp.cpp --------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -12,7 +11,6 @@ #include "MICmdArgContext.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValThreadGrp constructor. // Type: Method. // Args: None. @@ -22,7 +20,6 @@ CMICmdArgValThreadGrp::CMICmdArgValThreadGrp() : m_nThreadGrp(0) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValThreadGrp constructor. // Type: Method. // Args: vrArgName - (R) Argument's name to search by. @@ -40,7 +37,6 @@ CMICmdArgValThreadGrp::CMICmdArgValThreadGrp(const CMIUtilString &vrArgName, m_nThreadGrp(0) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdArgValThreadGrp destructor. // Type: Overridden. // Args: None. @@ -50,7 +46,6 @@ CMICmdArgValThreadGrp::CMICmdArgValThreadGrp(const CMIUtilString &vrArgName, CMICmdArgValThreadGrp::~CMICmdArgValThreadGrp() {} //++ -//------------------------------------------------------------------------------------ // Details: Parse the command's argument options string and try to extract the // value *this // argument is looking for. @@ -100,7 +95,6 @@ bool CMICmdArgValThreadGrp::Validate(CMICmdArgContext &vwArgContext) { } //++ -//------------------------------------------------------------------------------------ // Details: Examine the string and determine if it is a valid string type // argument. // Type: Method. @@ -119,7 +113,6 @@ bool CMICmdArgValThreadGrp::IsArgThreadGrp(const CMIUtilString &vrTxt) const { } //++ -//------------------------------------------------------------------------------------ // Details: Extract the thread group number from the thread group argument. // Type: Method. // Args: vrTxt - (R) Some text. @@ -139,7 +132,6 @@ bool CMICmdArgValThreadGrp::ExtractNumber(const CMIUtilString &vrTxt) { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the thread group ID found in the argument. // Type: Method. // Args: None. diff --git a/tools/lldb-mi/MICmdArgValThreadGrp.h b/tools/lldb-mi/MICmdArgValThreadGrp.h index bcdb156a1b14..12d3a1e90244 100644 --- a/tools/lldb-mi/MICmdArgValThreadGrp.h +++ b/tools/lldb-mi/MICmdArgValThreadGrp.h @@ -1,9 +1,8 @@ //===-- MICmdArgValThreadGrp.h ----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdBase.cpp b/tools/lldb-mi/MICmdBase.cpp index 613f005cf754..df36cfe86420 100644 --- a/tools/lldb-mi/MICmdBase.cpp +++ b/tools/lldb-mi/MICmdBase.cpp @@ -1,9 +1,8 @@ //===-- MICmdBase.cpp -------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -15,7 +14,6 @@ #include "MICmnMIValueConst.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdBase constructor. // Type: Method. // Args: None. @@ -31,7 +29,6 @@ CMICmdBase::CMICmdBase() m_ThreadArgMandatory(false), m_FrameArgMandatory(false) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdBase destructor. // Type: Overrideable. // Args: None. @@ -41,7 +38,6 @@ CMICmdBase::CMICmdBase() CMICmdBase::~CMICmdBase() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. // Type: Overridden. // Args: None. @@ -51,7 +47,6 @@ CMICmdBase::~CMICmdBase() {} const SMICmdData &CMICmdBase::GetCmdData() const { return m_cmdData; } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. // Type: Overridden. // Args: None. @@ -64,7 +59,6 @@ const CMIUtilString &CMICmdBase::GetErrorDescription() const { } //++ -//------------------------------------------------------------------------------------ // Details: The CMICmdFactory requires this function. Retrieve the command and // argument // options description string. @@ -76,7 +70,6 @@ const CMIUtilString &CMICmdBase::GetErrorDescription() const { const CMIUtilString &CMICmdBase::GetMiCmd() const { return m_strMiCmd; } //++ -//------------------------------------------------------------------------------------ // Details: Help parse the arguments that are common to all commands. // Args: None. // Return: None @@ -96,7 +89,6 @@ void CMICmdBase::AddCommonArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. A command must be given working // data and // provide data about its status or provide information to other @@ -111,7 +103,6 @@ void CMICmdBase::SetCmdData(const SMICmdData &vCmdData) { } //++ -//------------------------------------------------------------------------------------ // Details: The command factory requires this function. The factory calls this // function // so it can obtain *this command's creation function. @@ -125,7 +116,6 @@ CMICmdFactory::CmdCreatorFnPtr CMICmdBase::GetCmdCreatorFn() const { } //++ -//------------------------------------------------------------------------------------ // Details: If a command is an event type (has callbacks registered with // SBListener) it // needs to inform the Invoker that it has finished its work so that @@ -144,7 +134,6 @@ void CMICmdBase::CmdFinishedTellInvoker() const { } //++ -//------------------------------------------------------------------------------------ // Details: Returns the final version of the MI result record built up in the // command's // Acknowledge function. The one line text of MI result. @@ -158,7 +147,6 @@ const CMIUtilString &CMICmdBase::GetMIResultRecord() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve from the command additional MI result to its 1 line // response. // Because of using LLDB additional 'fake'/hack output is sometimes @@ -174,7 +162,6 @@ const CMIUtilString &CMICmdBase::GetMIResultRecordExtra() const { } //++ -//------------------------------------------------------------------------------------ // Details: Hss *this command got additional MI result to its 1 line response. // Because of using LLDB additional 'fake'/hack output is sometimes // required to @@ -190,7 +177,6 @@ bool CMICmdBase::HasMIResultRecordExtra() const { } //++ -//------------------------------------------------------------------------------------ // Details: Short cut function to enter error information into the command's // metadata // object and set the command's error status. @@ -213,7 +199,6 @@ void CMICmdBase::SetError(const CMIUtilString &rErrMsg) { } //++ -//------------------------------------------------------------------------------------ // Details: Short cut function to check MI command's execute status and // set an error in case of failure. // Type: Method. @@ -237,7 +222,6 @@ bool CMICmdBase::HandleSBError(const lldb::SBError &error, } //++ -//------------------------------------------------------------------------------------ // Details: Short cut function to check MI command's execute status and // call specified handler function for success case. // Type: Method. @@ -254,7 +238,6 @@ bool CMICmdBase::HandleSBErrorWithSuccess( } //++ -//------------------------------------------------------------------------------------ // Details: Short cut function to check MI command's execute status and // call specified handler function for error case. // Type: Method. @@ -271,7 +254,6 @@ bool CMICmdBase::HandleSBErrorWithFailure( } //++ -//------------------------------------------------------------------------------------ // Details: Ask a command to provide its unique identifier. // Type: Method. // Args: A unique identifier for this command class. @@ -287,7 +269,6 @@ MIuint CMICmdBase::GetGUID() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -304,7 +285,6 @@ bool CMICmdBase::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: Having previously given CMICmdArgSet m_setCmdArgs all the argument // or option // definitions for the command to handle proceed to parse and validate @@ -331,7 +311,6 @@ bool CMICmdBase::ParseValidateCmdOptions() { } //++ -//------------------------------------------------------------------------------------ // Details: If the MI Driver is not operating via a client i.e. Eclipse but say // operating // on a executable passed in as a argument to the drive then what diff --git a/tools/lldb-mi/MICmdBase.h b/tools/lldb-mi/MICmdBase.h index fe6aadd66999..4e32ed6a5262 100644 --- a/tools/lldb-mi/MICmdBase.h +++ b/tools/lldb-mi/MICmdBase.h @@ -1,9 +1,8 @@ //===-- MICmdBase.h ---------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -137,7 +136,6 @@ protected: }; //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the command argument or option object pointer so that it // can be // examined. If the option found and valid get the value (number, @@ -171,7 +169,6 @@ T *CMICmdBase::GetOption(const CMIUtilString &vStrOptionName) { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the command argument or option object pointer using // template function // CMICmdBase::GetOption(). Should the argument (by name) not be found diff --git a/tools/lldb-mi/MICmdCmd.cpp b/tools/lldb-mi/MICmdCmd.cpp index a784580673f0..081cff6fa51f 100644 --- a/tools/lldb-mi/MICmdCmd.cpp +++ b/tools/lldb-mi/MICmdCmd.cpp @@ -1,9 +1,8 @@ //===-- MICmdCmd.cpp --------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -15,7 +14,6 @@ #include "MICmdCmd.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdEnablePrettyPrinting constructor. // Type: Method. // Args: None. @@ -31,7 +29,6 @@ CMICmdCmdEnablePrettyPrinting::CMICmdCmdEnablePrettyPrinting() { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdEnablePrettyPrinting destructor. // Type: Overrideable. // Args: None. @@ -41,7 +38,6 @@ CMICmdCmdEnablePrettyPrinting::CMICmdCmdEnablePrettyPrinting() { CMICmdCmdEnablePrettyPrinting::~CMICmdCmdEnablePrettyPrinting() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -58,7 +54,6 @@ bool CMICmdCmdEnablePrettyPrinting::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -80,7 +75,6 @@ bool CMICmdCmdEnablePrettyPrinting::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -93,12 +87,8 @@ CMICmdBase *CMICmdCmdEnablePrettyPrinting::CreateSelf() { return new CMICmdCmdEnablePrettyPrinting(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdSource constructor. // Type: Method. // Args: None. @@ -114,7 +104,6 @@ CMICmdCmdSource::CMICmdCmdSource() { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdSource destructor. // Type: Overrideable. // Args: None. @@ -124,7 +113,6 @@ CMICmdCmdSource::CMICmdCmdSource() { CMICmdCmdSource::~CMICmdCmdSource() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -141,7 +129,6 @@ bool CMICmdCmdSource::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -160,7 +147,6 @@ bool CMICmdCmdSource::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. diff --git a/tools/lldb-mi/MICmdCmd.h b/tools/lldb-mi/MICmdCmd.h index d3de49c4ded7..aeaaa4b01db6 100644 --- a/tools/lldb-mi/MICmdCmd.h +++ b/tools/lldb-mi/MICmdCmd.h @@ -1,9 +1,8 @@ //===-- MICmdCmd.h ----------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdCmdBreak.cpp b/tools/lldb-mi/MICmdCmdBreak.cpp index 0e42f8562ab4..1cd0bacf51d5 100644 --- a/tools/lldb-mi/MICmdCmdBreak.cpp +++ b/tools/lldb-mi/MICmdCmdBreak.cpp @@ -1,9 +1,8 @@ //===-- MICmdCmdBreak.cpp ---------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -34,7 +33,6 @@ #include "MICmnStreamStdout.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdBreakInsert constructor. // Type: Method. // Args: None. @@ -58,7 +56,6 @@ CMICmdCmdBreakInsert::CMICmdCmdBreakInsert() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdBreakInsert destructor. // Type: Overrideable. // Args: None. @@ -68,7 +65,6 @@ CMICmdCmdBreakInsert::CMICmdCmdBreakInsert() CMICmdCmdBreakInsert::~CMICmdCmdBreakInsert() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -105,7 +101,6 @@ bool CMICmdCmdBreakInsert::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Helper function for CMICmdCmdBreakInsert::Execute(). // // Given a string, return the position of the ':' separator in 'file:func' @@ -123,7 +118,6 @@ static size_t findFileSeparatorPos(const std::string &x) { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -324,7 +318,6 @@ bool CMICmdCmdBreakInsert::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -360,7 +353,6 @@ bool CMICmdCmdBreakInsert::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -373,12 +365,8 @@ CMICmdBase *CMICmdCmdBreakInsert::CreateSelf() { return new CMICmdCmdBreakInsert(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdBreakDelete constructor. // Type: Method. // Args: None. @@ -395,7 +383,6 @@ CMICmdCmdBreakDelete::CMICmdCmdBreakDelete() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdBreakDelete destructor. // Type: Overrideable. // Args: None. @@ -405,7 +392,6 @@ CMICmdCmdBreakDelete::CMICmdCmdBreakDelete() CMICmdCmdBreakDelete::~CMICmdCmdBreakDelete() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -423,7 +409,6 @@ bool CMICmdCmdBreakDelete::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -462,7 +447,6 @@ bool CMICmdCmdBreakDelete::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -481,7 +465,6 @@ bool CMICmdCmdBreakDelete::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -494,12 +477,8 @@ CMICmdBase *CMICmdCmdBreakDelete::CreateSelf() { return new CMICmdCmdBreakDelete(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdBreakDisable constructor. // Type: Method. // Args: None. @@ -517,7 +496,6 @@ CMICmdCmdBreakDisable::CMICmdCmdBreakDisable() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdBreakDisable destructor. // Type: Overrideable. // Args: None. @@ -527,7 +505,6 @@ CMICmdCmdBreakDisable::CMICmdCmdBreakDisable() CMICmdCmdBreakDisable::~CMICmdCmdBreakDisable() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -545,7 +522,6 @@ bool CMICmdCmdBreakDisable::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -582,7 +558,6 @@ bool CMICmdCmdBreakDisable::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -613,7 +588,6 @@ bool CMICmdCmdBreakDisable::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -626,12 +600,8 @@ CMICmdBase *CMICmdCmdBreakDisable::CreateSelf() { return new CMICmdCmdBreakDisable(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdBreakEnable constructor. // Type: Method. // Args: None. @@ -649,7 +619,6 @@ CMICmdCmdBreakEnable::CMICmdCmdBreakEnable() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdBreakEnable destructor. // Type: Overrideable. // Args: None. @@ -659,7 +628,6 @@ CMICmdCmdBreakEnable::CMICmdCmdBreakEnable() CMICmdCmdBreakEnable::~CMICmdCmdBreakEnable() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -677,7 +645,6 @@ bool CMICmdCmdBreakEnable::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -714,7 +681,6 @@ bool CMICmdCmdBreakEnable::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -745,7 +711,6 @@ bool CMICmdCmdBreakEnable::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -758,12 +723,8 @@ CMICmdBase *CMICmdCmdBreakEnable::CreateSelf() { return new CMICmdCmdBreakEnable(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdBreakAfter constructor. // Type: Method. // Args: None. @@ -781,7 +742,6 @@ CMICmdCmdBreakAfter::CMICmdCmdBreakAfter() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdBreakAfter destructor. // Type: Overrideable. // Args: None. @@ -791,7 +751,6 @@ CMICmdCmdBreakAfter::CMICmdCmdBreakAfter() CMICmdCmdBreakAfter::~CMICmdCmdBreakAfter() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -809,7 +768,6 @@ bool CMICmdCmdBreakAfter::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -855,7 +813,6 @@ bool CMICmdCmdBreakAfter::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -874,7 +831,6 @@ bool CMICmdCmdBreakAfter::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -887,12 +843,8 @@ CMICmdBase *CMICmdCmdBreakAfter::CreateSelf() { return new CMICmdCmdBreakAfter(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdBreakCondition constructor. // Type: Method. // Args: None. @@ -915,7 +867,6 @@ CMICmdCmdBreakCondition::CMICmdCmdBreakCondition() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdBreakCondition destructor. // Type: Overrideable. // Args: None. @@ -925,7 +876,6 @@ CMICmdCmdBreakCondition::CMICmdCmdBreakCondition() CMICmdCmdBreakCondition::~CMICmdCmdBreakCondition() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -947,7 +897,6 @@ bool CMICmdCmdBreakCondition::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -994,7 +943,6 @@ bool CMICmdCmdBreakCondition::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -1013,7 +961,6 @@ bool CMICmdCmdBreakCondition::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -1027,7 +974,6 @@ CMICmdBase *CMICmdCmdBreakCondition::CreateSelf() { } //++ -//------------------------------------------------------------------------------------ // Details: A breakpoint expression can be passed to *this command as: // a single string i.e. '2' -> ok. // a quoted string i.e. "a > 100" -> ok diff --git a/tools/lldb-mi/MICmdCmdBreak.h b/tools/lldb-mi/MICmdCmdBreak.h index 7640e50a2bbf..00c5aa236eac 100644 --- a/tools/lldb-mi/MICmdCmdBreak.h +++ b/tools/lldb-mi/MICmdCmdBreak.h @@ -1,9 +1,8 @@ //===-- MICmdCmdBreak.h -----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdCmdData.cpp b/tools/lldb-mi/MICmdCmdData.cpp index 7a4845bba430..e0a165765199 100644 --- a/tools/lldb-mi/MICmdCmdData.cpp +++ b/tools/lldb-mi/MICmdCmdData.cpp @@ -1,9 +1,8 @@ //===-- MICmdCmdData.cpp ----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -53,7 +52,6 @@ CMIUtilString IntToHexAddrStr(uint32_t number) { } // namespace //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataEvaluateExpression constructor. // Type: Method. // Args: None. @@ -72,7 +70,6 @@ CMICmdCmdDataEvaluateExpression::CMICmdCmdDataEvaluateExpression() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataEvaluateExpression destructor. // Type: Overrideable. // Args: None. @@ -82,7 +79,6 @@ CMICmdCmdDataEvaluateExpression::CMICmdCmdDataEvaluateExpression() CMICmdCmdDataEvaluateExpression::~CMICmdCmdDataEvaluateExpression() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -99,7 +95,6 @@ bool CMICmdCmdDataEvaluateExpression::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -151,7 +146,6 @@ bool CMICmdCmdDataEvaluateExpression::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -206,7 +200,6 @@ bool CMICmdCmdDataEvaluateExpression::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -220,7 +213,6 @@ CMICmdBase *CMICmdCmdDataEvaluateExpression::CreateSelf() { } //++ -//------------------------------------------------------------------------------------ // Details: Examine the expression string to see if it contains invalid // characters. // Type: Method. @@ -242,12 +234,8 @@ bool CMICmdCmdDataEvaluateExpression::HaveInvalidCharacterInExpression( return bFoundInvalidCharInExpression; } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataDisassemble constructor. // Type: Method. // Args: None. @@ -265,7 +253,6 @@ CMICmdCmdDataDisassemble::CMICmdCmdDataDisassemble() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataDisassemble destructor. // Type: Overrideable. // Args: None. @@ -275,7 +262,6 @@ CMICmdCmdDataDisassemble::CMICmdCmdDataDisassemble() CMICmdCmdDataDisassemble::~CMICmdCmdDataDisassemble() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -297,7 +283,6 @@ bool CMICmdCmdDataDisassemble::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -416,10 +401,14 @@ bool CMICmdCmdDataDisassemble::Execute() { const MIuint nLine = lineEntry.GetLine(); const char *pFileName = lineEntry.GetFileSpec().GetFilename(); pFileName = (pFileName != nullptr) ? pFileName : pUnknown; + // Get a full path to the file. + char pathBuffer[PATH_MAX]; + lineEntry.GetFileSpec().GetPath(pathBuffer, PATH_MAX); - // MI "src_and_asm_line={line=\"%u\",file=\"%s\",line_asm_insn=[ ]}" + // MI "src_and_asm_line={line=\"%u\",file=\"%s\",line_asm_insn=[ ], + // fullname=\"%s\"}" const CMICmnMIValueConst miValueConst( - CMIUtilString::Format("0x%u", nLine)); + CMIUtilString::Format("%u", nLine)); const CMICmnMIValueResult miValueResult("line", miValueConst); CMICmnMIValueTuple miValueTuple2(miValueResult); const CMICmnMIValueConst miValueConst2(pFileName); @@ -428,6 +417,9 @@ bool CMICmdCmdDataDisassemble::Execute() { const CMICmnMIValueList miValueList(miValueTuple); const CMICmnMIValueResult miValueResult3("line_asm_insn", miValueList); miValueTuple2.Add(miValueResult3); + const CMICmnMIValueConst miValueConst5(pathBuffer); + const CMICmnMIValueResult miValueResult5("fullname", miValueConst5); + miValueTuple2.Add(miValueResult5); const CMICmnMIValueResult miValueResult4("src_and_asm_line", miValueTuple2); m_miValueList.Add(miValueResult4); @@ -440,7 +432,6 @@ bool CMICmdCmdDataDisassemble::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -461,7 +452,6 @@ bool CMICmdCmdDataDisassemble::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -474,12 +464,8 @@ CMICmdBase *CMICmdCmdDataDisassemble::CreateSelf() { return new CMICmdCmdDataDisassemble(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataReadMemoryBytes constructor. // Type: Method. // Args: None. @@ -498,7 +484,6 @@ CMICmdCmdDataReadMemoryBytes::CMICmdCmdDataReadMemoryBytes() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataReadMemoryBytes destructor. // Type: Overrideable. // Args: None. @@ -513,7 +498,6 @@ CMICmdCmdDataReadMemoryBytes::~CMICmdCmdDataReadMemoryBytes() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -534,7 +518,6 @@ bool CMICmdCmdDataReadMemoryBytes::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -664,7 +647,6 @@ bool CMICmdCmdDataReadMemoryBytes::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -712,7 +694,6 @@ bool CMICmdCmdDataReadMemoryBytes::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -725,12 +706,8 @@ CMICmdBase *CMICmdCmdDataReadMemoryBytes::CreateSelf() { return new CMICmdCmdDataReadMemoryBytes(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataReadMemory constructor. // Type: Method. // Args: None. @@ -746,7 +723,6 @@ CMICmdCmdDataReadMemory::CMICmdCmdDataReadMemory() { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataReadMemory destructor. // Type: Overrideable. // Args: None. @@ -756,7 +732,6 @@ CMICmdCmdDataReadMemory::CMICmdCmdDataReadMemory() { CMICmdCmdDataReadMemory::~CMICmdCmdDataReadMemory() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -773,7 +748,6 @@ bool CMICmdCmdDataReadMemory::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -798,7 +772,6 @@ bool CMICmdCmdDataReadMemory::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -811,12 +784,8 @@ CMICmdBase *CMICmdCmdDataReadMemory::CreateSelf() { return new CMICmdCmdDataReadMemory(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataListRegisterNames constructor. // Type: Method. // Args: None. @@ -833,7 +802,6 @@ CMICmdCmdDataListRegisterNames::CMICmdCmdDataListRegisterNames() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataReadMemoryBytes destructor. // Type: Overrideable. // Args: None. @@ -843,7 +811,6 @@ CMICmdCmdDataListRegisterNames::CMICmdCmdDataListRegisterNames() CMICmdCmdDataListRegisterNames::~CMICmdCmdDataListRegisterNames() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -861,7 +828,6 @@ bool CMICmdCmdDataListRegisterNames::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -926,7 +892,6 @@ bool CMICmdCmdDataListRegisterNames::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -947,7 +912,6 @@ bool CMICmdCmdDataListRegisterNames::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -961,7 +925,6 @@ CMICmdBase *CMICmdCmdDataListRegisterNames::CreateSelf() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -995,12 +958,8 @@ CMICmdCmdDataListRegisterNames::GetRegister(const MIuint vRegisterIndex) const { return lldb::SBValue(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataListRegisterValues constructor. // Type: Method. // Args: None. @@ -1018,7 +977,6 @@ CMICmdCmdDataListRegisterValues::CMICmdCmdDataListRegisterValues() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataListRegisterValues destructor. // Type: Overrideable. // Args: None. @@ -1028,7 +986,6 @@ CMICmdCmdDataListRegisterValues::CMICmdCmdDataListRegisterValues() CMICmdCmdDataListRegisterValues::~CMICmdCmdDataListRegisterValues() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -1051,7 +1008,6 @@ bool CMICmdCmdDataListRegisterValues::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -1133,7 +1089,6 @@ bool CMICmdCmdDataListRegisterValues::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -1154,7 +1109,6 @@ bool CMICmdCmdDataListRegisterValues::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -1168,7 +1122,6 @@ CMICmdBase *CMICmdCmdDataListRegisterValues::CreateSelf() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -1203,7 +1156,6 @@ lldb::SBValue CMICmdCmdDataListRegisterValues::GetRegister( } //++ -//------------------------------------------------------------------------------------ // Details: Adds the register value to the output list. // Type: Method. // Args: Value of the register, its index and output format. @@ -1225,12 +1177,8 @@ void CMICmdCmdDataListRegisterValues::AddToOutput( m_miValueList.Add(miValueTuple); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataListRegisterChanged constructor. // Type: Method. // Args: None. @@ -1246,7 +1194,6 @@ CMICmdCmdDataListRegisterChanged::CMICmdCmdDataListRegisterChanged() { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataListRegisterChanged destructor. // Type: Overrideable. // Args: None. @@ -1256,7 +1203,6 @@ CMICmdCmdDataListRegisterChanged::CMICmdCmdDataListRegisterChanged() { CMICmdCmdDataListRegisterChanged::~CMICmdCmdDataListRegisterChanged() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -1274,7 +1220,6 @@ bool CMICmdCmdDataListRegisterChanged::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -1296,7 +1241,6 @@ bool CMICmdCmdDataListRegisterChanged::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -1309,12 +1253,8 @@ CMICmdBase *CMICmdCmdDataListRegisterChanged::CreateSelf() { return new CMICmdCmdDataListRegisterChanged(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataWriteMemoryBytes constructor. // Type: Method. // Args: None. @@ -1332,7 +1272,6 @@ CMICmdCmdDataWriteMemoryBytes::CMICmdCmdDataWriteMemoryBytes() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataWriteMemoryBytes destructor. // Type: Overrideable. // Args: None. @@ -1342,7 +1281,6 @@ CMICmdCmdDataWriteMemoryBytes::CMICmdCmdDataWriteMemoryBytes() CMICmdCmdDataWriteMemoryBytes::~CMICmdCmdDataWriteMemoryBytes() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -1363,7 +1301,6 @@ bool CMICmdCmdDataWriteMemoryBytes::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -1388,7 +1325,6 @@ bool CMICmdCmdDataWriteMemoryBytes::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -1410,7 +1346,6 @@ bool CMICmdCmdDataWriteMemoryBytes::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -1423,12 +1358,8 @@ CMICmdBase *CMICmdCmdDataWriteMemoryBytes::CreateSelf() { return new CMICmdCmdDataWriteMemoryBytes(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataWriteMemory constructor. // Type: Method. // Args: None. @@ -1448,7 +1379,6 @@ CMICmdCmdDataWriteMemory::CMICmdCmdDataWriteMemory() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataWriteMemory destructor. // Type: Overrideable. // Args: None. @@ -1463,7 +1393,6 @@ CMICmdCmdDataWriteMemory::~CMICmdCmdDataWriteMemory() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -1485,7 +1414,6 @@ bool CMICmdCmdDataWriteMemory::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -1549,7 +1477,6 @@ bool CMICmdCmdDataWriteMemory::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -1568,7 +1495,6 @@ bool CMICmdCmdDataWriteMemory::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -1581,12 +1507,8 @@ CMICmdBase *CMICmdCmdDataWriteMemory::CreateSelf() { return new CMICmdCmdDataWriteMemory(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataInfoLine constructor. // Type: Method. // Args: None. @@ -1605,7 +1527,6 @@ CMICmdCmdDataInfoLine::CMICmdCmdDataInfoLine() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdDataInfoLine destructor. // Type: Overrideable. // Args: None. @@ -1615,7 +1536,6 @@ CMICmdCmdDataInfoLine::CMICmdCmdDataInfoLine() CMICmdCmdDataInfoLine::~CMICmdCmdDataInfoLine() = default; //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -1631,7 +1551,6 @@ bool CMICmdCmdDataInfoLine::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -1726,7 +1645,6 @@ bool CMICmdCmdDataInfoLine::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -1742,7 +1660,6 @@ bool CMICmdCmdDataInfoLine::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. diff --git a/tools/lldb-mi/MICmdCmdData.h b/tools/lldb-mi/MICmdCmdData.h index 0317db11a535..19c5319faab3 100644 --- a/tools/lldb-mi/MICmdCmdData.h +++ b/tools/lldb-mi/MICmdCmdData.h @@ -1,9 +1,8 @@ //===-- MICmdCmdData.h ------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdCmdEnviro.cpp b/tools/lldb-mi/MICmdCmdEnviro.cpp index 298fe0d57bec..e7a92f3c9e89 100644 --- a/tools/lldb-mi/MICmdCmdEnviro.cpp +++ b/tools/lldb-mi/MICmdCmdEnviro.cpp @@ -1,9 +1,8 @@ //===-- MICmdCmdEnviro.cpp --------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -18,7 +17,6 @@ #include "MICmnMIValueConst.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdEnvironmentCd constructor. // Type: Method. // Args: None. @@ -35,7 +33,6 @@ CMICmdCmdEnvironmentCd::CMICmdCmdEnvironmentCd() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdEnvironmentCd destructor. // Type: Overrideable. // Args: None. @@ -45,7 +42,6 @@ CMICmdCmdEnvironmentCd::CMICmdCmdEnvironmentCd() CMICmdCmdEnvironmentCd::~CMICmdCmdEnvironmentCd() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -62,7 +58,6 @@ bool CMICmdCmdEnvironmentCd::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -105,7 +100,6 @@ bool CMICmdCmdEnvironmentCd::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -138,7 +132,6 @@ bool CMICmdCmdEnvironmentCd::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. diff --git a/tools/lldb-mi/MICmdCmdEnviro.h b/tools/lldb-mi/MICmdCmdEnviro.h index 5c663203143a..461ccd83a8f5 100644 --- a/tools/lldb-mi/MICmdCmdEnviro.h +++ b/tools/lldb-mi/MICmdCmdEnviro.h @@ -1,9 +1,8 @@ //===-- MICmdCmdEnviro.h ----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdCmdExec.cpp b/tools/lldb-mi/MICmdCmdExec.cpp index 1102b952407e..ffdf171aef08 100644 --- a/tools/lldb-mi/MICmdCmdExec.cpp +++ b/tools/lldb-mi/MICmdCmdExec.cpp @@ -1,9 +1,8 @@ //===-- MICmdCmdExec.cpp ----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -42,7 +41,6 @@ #include "MIDriver.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecRun constructor. // Type: Method. // Args: None. @@ -58,7 +56,6 @@ CMICmdCmdExecRun::CMICmdCmdExecRun() : m_constStrArgStart("start") { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecRun destructor. // Type: Overrideable. // Args: None. @@ -68,7 +65,6 @@ CMICmdCmdExecRun::CMICmdCmdExecRun() : m_constStrArgStart("start") { CMICmdCmdExecRun::~CMICmdCmdExecRun() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. It parses the command line // options' // arguments to extract values for each of those arguments. @@ -86,7 +82,6 @@ bool CMICmdCmdExecRun::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -148,7 +143,6 @@ bool CMICmdCmdExecRun::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -182,7 +176,6 @@ bool CMICmdCmdExecRun::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -193,12 +186,8 @@ bool CMICmdCmdExecRun::Acknowledge() { //-- CMICmdBase *CMICmdCmdExecRun::CreateSelf() { return new CMICmdCmdExecRun(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecContinue constructor. // Type: Method. // Args: None. @@ -214,7 +203,6 @@ CMICmdCmdExecContinue::CMICmdCmdExecContinue() { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecContinue destructor. // Type: Overrideable. // Args: None. @@ -224,7 +212,6 @@ CMICmdCmdExecContinue::CMICmdCmdExecContinue() { CMICmdCmdExecContinue::~CMICmdCmdExecContinue() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -254,7 +241,6 @@ bool CMICmdCmdExecContinue::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -271,7 +257,6 @@ bool CMICmdCmdExecContinue::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -284,12 +269,8 @@ CMICmdBase *CMICmdCmdExecContinue::CreateSelf() { return new CMICmdCmdExecContinue(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecNext constructor. // Type: Method. // Args: None. @@ -305,7 +286,6 @@ CMICmdCmdExecNext::CMICmdCmdExecNext() : m_constStrArgNumber("number") { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecNext destructor. // Type: Overrideable. // Args: None. @@ -315,7 +295,6 @@ CMICmdCmdExecNext::CMICmdCmdExecNext() : m_constStrArgNumber("number") { CMICmdCmdExecNext::~CMICmdCmdExecNext() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -331,7 +310,6 @@ bool CMICmdCmdExecNext::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -376,7 +354,6 @@ bool CMICmdCmdExecNext::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -393,7 +370,6 @@ bool CMICmdCmdExecNext::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -404,12 +380,8 @@ bool CMICmdCmdExecNext::Acknowledge() { //-- CMICmdBase *CMICmdCmdExecNext::CreateSelf() { return new CMICmdCmdExecNext(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecStep constructor. // Type: Method. // Args: None. @@ -425,7 +397,6 @@ CMICmdCmdExecStep::CMICmdCmdExecStep() : m_constStrArgNumber("number") { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecStep destructor. // Type: Overrideable. // Args: None. @@ -435,7 +406,6 @@ CMICmdCmdExecStep::CMICmdCmdExecStep() : m_constStrArgNumber("number") { CMICmdCmdExecStep::~CMICmdCmdExecStep() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -451,7 +421,6 @@ bool CMICmdCmdExecStep::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -497,7 +466,6 @@ bool CMICmdCmdExecStep::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -514,7 +482,6 @@ bool CMICmdCmdExecStep::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -525,12 +492,8 @@ bool CMICmdCmdExecStep::Acknowledge() { //-- CMICmdBase *CMICmdCmdExecStep::CreateSelf() { return new CMICmdCmdExecStep(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecNextInstruction constructor. // Type: Method. // Args: None. @@ -547,7 +510,6 @@ CMICmdCmdExecNextInstruction::CMICmdCmdExecNextInstruction() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecNextInstruction destructor. // Type: Overrideable. // Args: None. @@ -557,7 +519,6 @@ CMICmdCmdExecNextInstruction::CMICmdCmdExecNextInstruction() CMICmdCmdExecNextInstruction::~CMICmdCmdExecNextInstruction() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -573,7 +534,6 @@ bool CMICmdCmdExecNextInstruction::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -619,7 +579,6 @@ bool CMICmdCmdExecNextInstruction::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -636,7 +595,6 @@ bool CMICmdCmdExecNextInstruction::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -649,12 +607,8 @@ CMICmdBase *CMICmdCmdExecNextInstruction::CreateSelf() { return new CMICmdCmdExecNextInstruction(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecStepInstruction constructor. // Type: Method. // Args: None. @@ -671,7 +625,6 @@ CMICmdCmdExecStepInstruction::CMICmdCmdExecStepInstruction() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecStepInstruction destructor. // Type: Overrideable. // Args: None. @@ -681,7 +634,6 @@ CMICmdCmdExecStepInstruction::CMICmdCmdExecStepInstruction() CMICmdCmdExecStepInstruction::~CMICmdCmdExecStepInstruction() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -697,7 +649,6 @@ bool CMICmdCmdExecStepInstruction::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -743,7 +694,6 @@ bool CMICmdCmdExecStepInstruction::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -760,7 +710,6 @@ bool CMICmdCmdExecStepInstruction::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -773,12 +722,8 @@ CMICmdBase *CMICmdCmdExecStepInstruction::CreateSelf() { return new CMICmdCmdExecStepInstruction(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecFinish constructor. // Type: Method. // Args: None. @@ -794,7 +739,6 @@ CMICmdCmdExecFinish::CMICmdCmdExecFinish() { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecFinish destructor. // Type: Overrideable. // Args: None. @@ -804,7 +748,6 @@ CMICmdCmdExecFinish::CMICmdCmdExecFinish() { CMICmdCmdExecFinish::~CMICmdCmdExecFinish() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -817,7 +760,6 @@ CMICmdCmdExecFinish::~CMICmdCmdExecFinish() {} bool CMICmdCmdExecFinish::ParseArgs() { return ParseValidateCmdOptions(); } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -862,7 +804,6 @@ bool CMICmdCmdExecFinish::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -879,7 +820,6 @@ bool CMICmdCmdExecFinish::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -892,12 +832,8 @@ CMICmdBase *CMICmdCmdExecFinish::CreateSelf() { return new CMICmdCmdExecFinish(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecInterrupt constructor. // Type: Method. // Args: None. @@ -913,7 +849,6 @@ CMICmdCmdExecInterrupt::CMICmdCmdExecInterrupt() { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecInterrupt destructor. // Type: Overrideable. // Args: None. @@ -923,7 +858,6 @@ CMICmdCmdExecInterrupt::CMICmdCmdExecInterrupt() { CMICmdCmdExecInterrupt::~CMICmdCmdExecInterrupt() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -954,7 +888,6 @@ bool CMICmdCmdExecInterrupt::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -971,7 +904,6 @@ bool CMICmdCmdExecInterrupt::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -984,12 +916,8 @@ CMICmdBase *CMICmdCmdExecInterrupt::CreateSelf() { return new CMICmdCmdExecInterrupt(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecArguments constructor. // Type: Method. // Args: None. @@ -1006,7 +934,6 @@ CMICmdCmdExecArguments::CMICmdCmdExecArguments() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecArguments destructor. // Type: Overrideable. // Args: None. @@ -1016,7 +943,6 @@ CMICmdCmdExecArguments::CMICmdCmdExecArguments() CMICmdCmdExecArguments::~CMICmdCmdExecArguments() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -1034,7 +960,6 @@ bool CMICmdCmdExecArguments::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -1058,13 +983,13 @@ bool CMICmdCmdExecArguments::Execute() { } lldb::SBLaunchInfo sbLaunchInfo = sbTarget.GetLaunchInfo(); - sbLaunchInfo.SetArguments(NULL, false); + sbLaunchInfo.SetArguments(nullptr, false); CMIUtilString strArg; size_t nArgIndex = 0; while (pArgArguments->GetExpectedOption<CMICmdArgValString, CMIUtilString>( strArg, nArgIndex)) { - const char *argv[2] = {strArg.c_str(), NULL}; + const char *argv[2] = {strArg.c_str(), nullptr}; sbLaunchInfo.SetArguments(argv, true); ++nArgIndex; } @@ -1075,7 +1000,6 @@ bool CMICmdCmdExecArguments::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -1092,7 +1016,6 @@ bool CMICmdCmdExecArguments::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -1105,12 +1028,8 @@ CMICmdBase *CMICmdCmdExecArguments::CreateSelf() { return new CMICmdCmdExecArguments(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecAbort constructor. // Type: Method. // Args: None. @@ -1126,7 +1045,6 @@ CMICmdCmdExecAbort::CMICmdCmdExecAbort() { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdExecAbort destructor. // Type: Overrideable. // Args: None. @@ -1136,7 +1054,6 @@ CMICmdCmdExecAbort::CMICmdCmdExecAbort() { CMICmdCmdExecAbort::~CMICmdCmdExecAbort() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -1169,7 +1086,6 @@ bool CMICmdCmdExecAbort::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -1186,7 +1102,6 @@ bool CMICmdCmdExecAbort::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. diff --git a/tools/lldb-mi/MICmdCmdExec.h b/tools/lldb-mi/MICmdCmdExec.h index 451d25e29eb1..8533915e24f8 100644 --- a/tools/lldb-mi/MICmdCmdExec.h +++ b/tools/lldb-mi/MICmdCmdExec.h @@ -1,9 +1,8 @@ //===-- MICmdCmdExec.h ------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdCmdFile.cpp b/tools/lldb-mi/MICmdCmdFile.cpp index 9e3ea273b07b..8b105eb1d58a 100644 --- a/tools/lldb-mi/MICmdCmdFile.cpp +++ b/tools/lldb-mi/MICmdCmdFile.cpp @@ -1,9 +1,8 @@ //===-- MICmdCmdFile.cpp ----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -24,7 +23,6 @@ #include "MIUtilFileStd.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdFileExecAndSymbols constructor. // Type: Method. // Args: None. @@ -42,7 +40,6 @@ CMICmdCmdFileExecAndSymbols::CMICmdCmdFileExecAndSymbols() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdFileExecAndSymbols destructor. // Type: Overrideable. // Args: None. @@ -52,7 +49,6 @@ CMICmdCmdFileExecAndSymbols::CMICmdCmdFileExecAndSymbols() CMICmdCmdFileExecAndSymbols::~CMICmdCmdFileExecAndSymbols() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -74,7 +70,6 @@ bool CMICmdCmdFileExecAndSymbols::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -160,7 +155,6 @@ bool CMICmdCmdFileExecAndSymbols::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -179,7 +173,6 @@ bool CMICmdCmdFileExecAndSymbols::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -193,7 +186,6 @@ CMICmdBase *CMICmdCmdFileExecAndSymbols::CreateSelf() { } //++ -//------------------------------------------------------------------------------------ // Details: If the MI Driver is not operating via a client i.e. Eclipse but say // operating // on a executable passed in as a argument to the drive then what diff --git a/tools/lldb-mi/MICmdCmdFile.h b/tools/lldb-mi/MICmdCmdFile.h index 0a25200cda8d..4607f748cba5 100644 --- a/tools/lldb-mi/MICmdCmdFile.h +++ b/tools/lldb-mi/MICmdCmdFile.h @@ -1,9 +1,8 @@ //===-- MICmdCmdFile.h ------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdCmdGdbInfo.cpp b/tools/lldb-mi/MICmdCmdGdbInfo.cpp index 5988066883d1..b351353ba1e9 100644 --- a/tools/lldb-mi/MICmdCmdGdbInfo.cpp +++ b/tools/lldb-mi/MICmdCmdGdbInfo.cpp @@ -1,9 +1,8 @@ //===-- MICmdCmdGdbInfo.cpp -------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -27,7 +26,6 @@ const CMICmdCmdGdbInfo::MapPrintFnNameToPrintFn_t {"sharedlibrary", &CMICmdCmdGdbInfo::PrintFnSharedLibrary}}; //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdGdbInfo constructor. // Type: Method. // Args: None. @@ -46,7 +44,6 @@ CMICmdCmdGdbInfo::CMICmdCmdGdbInfo() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdGdbInfo destructor. // Type: Overrideable. // Args: None. @@ -56,7 +53,6 @@ CMICmdCmdGdbInfo::CMICmdCmdGdbInfo() CMICmdCmdGdbInfo::~CMICmdCmdGdbInfo() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -72,7 +68,6 @@ bool CMICmdCmdGdbInfo::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -100,7 +95,6 @@ bool CMICmdCmdGdbInfo::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -141,7 +135,6 @@ bool CMICmdCmdGdbInfo::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -153,7 +146,6 @@ bool CMICmdCmdGdbInfo::Acknowledge() { CMICmdBase *CMICmdCmdGdbInfo::CreateSelf() { return new CMICmdCmdGdbInfo(); } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the print function's pointer for the matching print // request. // Type: Method. @@ -178,7 +170,6 @@ bool CMICmdCmdGdbInfo::GetPrintFn(const CMIUtilString &vrPrintFnName, } //++ -//------------------------------------------------------------------------------------ // Details: Carry out work to complete the request to prepare and send back // information // asked for. diff --git a/tools/lldb-mi/MICmdCmdGdbInfo.h b/tools/lldb-mi/MICmdCmdGdbInfo.h index 43daf8e82758..8ad69c49f59c 100644 --- a/tools/lldb-mi/MICmdCmdGdbInfo.h +++ b/tools/lldb-mi/MICmdCmdGdbInfo.h @@ -1,9 +1,8 @@ //===-- MICmdCmdGdbInfo.h ---------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdCmdGdbSet.cpp b/tools/lldb-mi/MICmdCmdGdbSet.cpp index b433f7678449..162e3d5a345d 100644 --- a/tools/lldb-mi/MICmdCmdGdbSet.cpp +++ b/tools/lldb-mi/MICmdCmdGdbSet.cpp @@ -1,9 +1,8 @@ //===-- MICmdCmdGdbSet.cpp --------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -32,7 +31,6 @@ const CMICmdCmdGdbSet::MapGdbOptionNameToFnGdbOptionPtr_t {"breakpoint", &CMICmdCmdGdbSet::OptionFnBreakpoint}}; //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdGdbSet constructor. // Type: Method. // Args: None. @@ -51,7 +49,6 @@ CMICmdCmdGdbSet::CMICmdCmdGdbSet() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdGdbSet destructor. // Type: Overrideable. // Args: None. @@ -61,7 +58,6 @@ CMICmdCmdGdbSet::CMICmdCmdGdbSet() CMICmdCmdGdbSet::~CMICmdCmdGdbSet() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -79,7 +75,6 @@ bool CMICmdCmdGdbSet::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command is executed in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -133,7 +128,6 @@ bool CMICmdCmdGdbSet::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute() method. @@ -180,7 +174,6 @@ bool CMICmdCmdGdbSet::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -192,7 +185,6 @@ bool CMICmdCmdGdbSet::Acknowledge() { CMICmdBase *CMICmdCmdGdbSet::CreateSelf() { return new CMICmdCmdGdbSet(); } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the print function's pointer for the matching print // request. // Type: Method. @@ -217,7 +209,6 @@ bool CMICmdCmdGdbSet::GetOptionFn(const CMIUtilString &vrPrintFnName, } //++ -//------------------------------------------------------------------------------------ // Details: Carry out work to complete the GDB set option 'target-async' to // prepare // and send back information asked for. @@ -262,7 +253,6 @@ bool CMICmdCmdGdbSet::OptionFnTargetAsync( } //++ -//------------------------------------------------------------------------------------ // Details: Carry out work to complete the GDB set option // 'print-char-array-as-string' to // prepare and send back information asked for. @@ -313,7 +303,6 @@ bool CMICmdCmdGdbSet::OptionFnPrint(const CMIUtilString::VecString_t &vrWords) { } //++ -//------------------------------------------------------------------------------------ // Details: Carry out work to complete the GDB set option 'solib-search-path' to // prepare // and send back information asked for. @@ -349,7 +338,6 @@ bool CMICmdCmdGdbSet::OptionFnSolibSearchPath( } //++ -//------------------------------------------------------------------------------------ // Details: Carry out work to complete the GDB set option 'output-radix' to // prepare // and send back information asked for. @@ -400,7 +388,6 @@ bool CMICmdCmdGdbSet::OptionFnOutputRadix( } //++ -//------------------------------------------------------------------------------------ // Details: Carry out work to complete the GDB set option 'disassembly-flavor' // to prepare // and send back information asked for. @@ -433,7 +420,6 @@ bool CMICmdCmdGdbSet::OptionFnDisassemblyFlavor( } //++ -//------------------------------------------------------------------------------------ // Details: Carry out work to complete the GDB set option 'breakpoint' to // prepare // and send back information asked for. @@ -483,7 +469,6 @@ bool CMICmdCmdGdbSet::OptionFnBreakpoint( } //++ -//------------------------------------------------------------------------------------ // Details: Carry out work to complete the GDB set option to prepare and send // back the // requested information. diff --git a/tools/lldb-mi/MICmdCmdGdbSet.h b/tools/lldb-mi/MICmdCmdGdbSet.h index 7cca20c3348d..c88f9976ef65 100644 --- a/tools/lldb-mi/MICmdCmdGdbSet.h +++ b/tools/lldb-mi/MICmdCmdGdbSet.h @@ -1,9 +1,8 @@ //===-- MICmdCmdGdbSet.h ----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdCmdGdbShow.cpp b/tools/lldb-mi/MICmdCmdGdbShow.cpp index 196b8271064f..9ebd36202b7d 100644 --- a/tools/lldb-mi/MICmdCmdGdbShow.cpp +++ b/tools/lldb-mi/MICmdCmdGdbShow.cpp @@ -1,9 +1,8 @@ //===-- MICmdCmdGdbShow.cpp -------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -36,7 +35,6 @@ const CMICmdCmdGdbShow::MapGdbOptionNameToFnGdbOptionPtr_t {"breakpoint", &CMICmdCmdGdbShow::OptionFnBreakpoint}}; //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdGdbShow constructor. // Type: Method. // Args: None. @@ -55,7 +53,6 @@ CMICmdCmdGdbShow::CMICmdCmdGdbShow() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdGdbShow destructor. // Type: Overrideable. // Args: None. @@ -65,7 +62,6 @@ CMICmdCmdGdbShow::CMICmdCmdGdbShow() CMICmdCmdGdbShow::~CMICmdCmdGdbShow() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -83,7 +79,6 @@ bool CMICmdCmdGdbShow::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command is executed in this // function. // Type: Overridden. @@ -135,7 +130,6 @@ bool CMICmdCmdGdbShow::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute() method. @@ -191,7 +185,6 @@ bool CMICmdCmdGdbShow::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -203,7 +196,6 @@ bool CMICmdCmdGdbShow::Acknowledge() { CMICmdBase *CMICmdCmdGdbShow::CreateSelf() { return new CMICmdCmdGdbShow(); } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the print function's pointer for the matching print // request. // Type: Method. @@ -228,7 +220,6 @@ bool CMICmdCmdGdbShow::GetOptionFn(const CMIUtilString &vrPrintFnName, } //++ -//------------------------------------------------------------------------------------ // Details: Carry out work to complete the GDB show option 'target-async' to // prepare // and send back the requested information. @@ -252,7 +243,6 @@ bool CMICmdCmdGdbShow::OptionFnTargetAsync( } //++ -//------------------------------------------------------------------------------------ // Details: Carry out work to complete the GDB show option 'print' to prepare // and send // back the requested information. @@ -303,7 +293,6 @@ bool CMICmdCmdGdbShow::OptionFnPrint( } //++ -//------------------------------------------------------------------------------------ // Details: Carry out work to complete the GDB show option 'language' to prepare // and send back the requested information. // Type: Method. @@ -329,7 +318,6 @@ bool CMICmdCmdGdbShow::OptionFnLanguage( } //++ -//------------------------------------------------------------------------------------ // Details: Carry out work to complete the GDB show option 'disassembly-flavor' to prepare // and send back the requested information. // Type: Method. @@ -349,7 +337,6 @@ bool CMICmdCmdGdbShow::OptionFnDisassemblyFlavor(const CMIUtilString::VecString_ } //++ -//------------------------------------------------------------------------------------ // Details: Carry out work to complete the GDB show option 'breakpoint' to // prepare // and send back the requested information. @@ -386,7 +373,6 @@ bool CMICmdCmdGdbShow::OptionFnBreakpoint( } //++ -//------------------------------------------------------------------------------------ // Details: Carry out work to complete the GDB show option to prepare and send // back the // requested information. diff --git a/tools/lldb-mi/MICmdCmdGdbShow.h b/tools/lldb-mi/MICmdCmdGdbShow.h index 51f07092843f..9de034c617cd 100644 --- a/tools/lldb-mi/MICmdCmdGdbShow.h +++ b/tools/lldb-mi/MICmdCmdGdbShow.h @@ -1,9 +1,8 @@ //===-- MICmdCmdGdbShow.h ---------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdCmdGdbThread.cpp b/tools/lldb-mi/MICmdCmdGdbThread.cpp index 06dc0c841099..132cf2c68ef8 100644 --- a/tools/lldb-mi/MICmdCmdGdbThread.cpp +++ b/tools/lldb-mi/MICmdCmdGdbThread.cpp @@ -1,9 +1,8 @@ //===-- MICmdCmdGdbThread.cpp -----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -15,7 +14,6 @@ #include "MICmnMIValueConst.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdGdbThread constructor. // Type: Method. // Args: None. @@ -31,7 +29,6 @@ CMICmdCmdGdbThread::CMICmdCmdGdbThread() { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdThread destructor. // Type: Overrideable. // Args: None. @@ -41,7 +38,6 @@ CMICmdCmdGdbThread::CMICmdCmdGdbThread() { CMICmdCmdGdbThread::~CMICmdCmdGdbThread() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -59,7 +55,6 @@ bool CMICmdCmdGdbThread::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -81,7 +76,6 @@ bool CMICmdCmdGdbThread::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. diff --git a/tools/lldb-mi/MICmdCmdGdbThread.h b/tools/lldb-mi/MICmdCmdGdbThread.h index 2f8b0bc0ad52..963001f01912 100644 --- a/tools/lldb-mi/MICmdCmdGdbThread.h +++ b/tools/lldb-mi/MICmdCmdGdbThread.h @@ -1,9 +1,8 @@ //===-- MICmdCmdGdbThread.h -------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdCmdMiscellanous.cpp b/tools/lldb-mi/MICmdCmdMiscellanous.cpp index 87c0ee62f658..5aa795999535 100644 --- a/tools/lldb-mi/MICmdCmdMiscellanous.cpp +++ b/tools/lldb-mi/MICmdCmdMiscellanous.cpp @@ -1,9 +1,8 @@ //===-- MICmdCmdMiscellanous.cpp --------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -35,7 +34,6 @@ #include "MIDriverBase.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdGdbExit constructor. // Type: Method. // Args: None. @@ -51,7 +49,6 @@ CMICmdCmdGdbExit::CMICmdCmdGdbExit() { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdGdbExit destructor. // Type: Overrideable. // Args: None. @@ -61,7 +58,6 @@ CMICmdCmdGdbExit::CMICmdCmdGdbExit() { CMICmdCmdGdbExit::~CMICmdCmdGdbExit() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -81,7 +77,6 @@ bool CMICmdCmdGdbExit::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -110,7 +105,6 @@ bool CMICmdCmdGdbExit::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -121,12 +115,8 @@ bool CMICmdCmdGdbExit::Acknowledge() { //-- CMICmdBase *CMICmdCmdGdbExit::CreateSelf() { return new CMICmdCmdGdbExit(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdListThreadGroups constructor. // Type: Method. // Args: None. @@ -146,7 +136,6 @@ CMICmdCmdListThreadGroups::CMICmdCmdListThreadGroups() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdListThreadGroups destructor. // Type: Overrideable. // Args: None. @@ -158,7 +147,6 @@ CMICmdCmdListThreadGroups::~CMICmdCmdListThreadGroups() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -183,7 +171,6 @@ bool CMICmdCmdListThreadGroups::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -254,7 +241,6 @@ bool CMICmdCmdListThreadGroups::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -340,7 +326,9 @@ bool CMICmdCmdListThreadGroups::Acknowledge() { const char *pDir = sbTrgt.GetExecutable().GetDirectory(); const char *pFileName = sbTrgt.GetExecutable().GetFilename(); const CMIUtilString strFile( - CMIUtilString::Format("%s/%s", pDir, pFileName)); + CMIUtilString::Format("%s/%s", + CMIUtilString::WithNullAsEmpty(pDir), + CMIUtilString::WithNullAsEmpty(pFileName))); const CMICmnMIValueConst miValueConst4(strFile); const CMICmnMIValueResult miValueResult4("executable", miValueConst4); miTuple.Add(miValueResult4); @@ -386,7 +374,6 @@ bool CMICmdCmdListThreadGroups::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -399,12 +386,8 @@ CMICmdBase *CMICmdCmdListThreadGroups::CreateSelf() { return new CMICmdCmdListThreadGroups(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdInterpreterExec constructor. // Type: Method. // Args: None. @@ -422,7 +405,6 @@ CMICmdCmdInterpreterExec::CMICmdCmdInterpreterExec() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdInterpreterExec destructor. // Type: Overrideable. // Args: None. @@ -432,7 +414,6 @@ CMICmdCmdInterpreterExec::CMICmdCmdInterpreterExec() CMICmdCmdInterpreterExec::~CMICmdCmdInterpreterExec() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -451,7 +432,6 @@ bool CMICmdCmdInterpreterExec::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -467,8 +447,7 @@ bool CMICmdCmdInterpreterExec::Execute() { CMICMDBASE_GETOPTION(pArgCommand, String, m_constStrArgNamedCommand); // Handle the interpreter parameter by do nothing on purpose (set to 'handled' - // in - // the arg definition above) + // in the arg definition above) const CMIUtilString &rStrInterpreter(pArgInterpreter->GetValue()); MIunused(rStrInterpreter); @@ -484,7 +463,6 @@ bool CMICmdCmdInterpreterExec::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -522,7 +500,6 @@ bool CMICmdCmdInterpreterExec::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -535,12 +512,8 @@ CMICmdBase *CMICmdCmdInterpreterExec::CreateSelf() { return new CMICmdCmdInterpreterExec(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdInferiorTtySet constructor. // Type: Method. // Args: None. @@ -556,7 +529,6 @@ CMICmdCmdInferiorTtySet::CMICmdCmdInferiorTtySet() { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdInferiorTtySet destructor. // Type: Overrideable. // Args: None. @@ -566,7 +538,6 @@ CMICmdCmdInferiorTtySet::CMICmdCmdInferiorTtySet() { CMICmdCmdInferiorTtySet::~CMICmdCmdInferiorTtySet() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -584,7 +555,6 @@ bool CMICmdCmdInferiorTtySet::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -603,7 +573,6 @@ bool CMICmdCmdInferiorTtySet::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. diff --git a/tools/lldb-mi/MICmdCmdMiscellanous.h b/tools/lldb-mi/MICmdCmdMiscellanous.h index af75c19b4dfd..614638e59345 100644 --- a/tools/lldb-mi/MICmdCmdMiscellanous.h +++ b/tools/lldb-mi/MICmdCmdMiscellanous.h @@ -1,9 +1,8 @@ //===-- MICmdCmdMiscellanous.h ----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdCmdStack.cpp b/tools/lldb-mi/MICmdCmdStack.cpp index b491027bf80e..599db37417f5 100644 --- a/tools/lldb-mi/MICmdCmdStack.cpp +++ b/tools/lldb-mi/MICmdCmdStack.cpp @@ -1,9 +1,8 @@ //===-- MICmdCmdStack.cpp ---------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -35,7 +34,6 @@ #include <algorithm> //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdStackInfoDepth constructor. // Type: Method. // Args: None. @@ -52,7 +50,6 @@ CMICmdCmdStackInfoDepth::CMICmdCmdStackInfoDepth() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdStackInfoDepth destructor. // Type: Overrideable. // Args: None. @@ -62,7 +59,6 @@ CMICmdCmdStackInfoDepth::CMICmdCmdStackInfoDepth() CMICmdCmdStackInfoDepth::~CMICmdCmdStackInfoDepth() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -78,7 +74,6 @@ bool CMICmdCmdStackInfoDepth::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -115,7 +110,6 @@ bool CMICmdCmdStackInfoDepth::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -138,7 +132,6 @@ bool CMICmdCmdStackInfoDepth::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -151,12 +144,8 @@ CMICmdBase *CMICmdCmdStackInfoDepth::CreateSelf() { return new CMICmdCmdStackInfoDepth(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdStackInfoFrame constructor. // Type: Method. // Args: None. @@ -172,7 +161,6 @@ CMICmdCmdStackInfoFrame::CMICmdCmdStackInfoFrame() { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdStackInfoFrame destructor. // Type: Overrideable. // Args: None. @@ -182,7 +170,6 @@ CMICmdCmdStackInfoFrame::CMICmdCmdStackInfoFrame() { CMICmdCmdStackInfoFrame::~CMICmdCmdStackInfoFrame() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -195,7 +182,6 @@ CMICmdCmdStackInfoFrame::~CMICmdCmdStackInfoFrame() {} bool CMICmdCmdStackInfoFrame::ParseArgs() { return ParseValidateCmdOptions(); } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -228,7 +214,6 @@ bool CMICmdCmdStackInfoFrame::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -249,7 +234,6 @@ bool CMICmdCmdStackInfoFrame::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -262,12 +246,8 @@ CMICmdBase *CMICmdCmdStackInfoFrame::CreateSelf() { return new CMICmdCmdStackInfoFrame(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdStackListFrames constructor. // Type: Method. // Args: None. @@ -285,7 +265,6 @@ CMICmdCmdStackListFrames::CMICmdCmdStackListFrames() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdStackListFrames destructor. // Type: Overrideable. // Args: None. @@ -297,7 +276,6 @@ CMICmdCmdStackListFrames::~CMICmdCmdStackListFrames() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -314,7 +292,6 @@ bool CMICmdCmdStackListFrames::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -383,7 +360,6 @@ bool CMICmdCmdStackListFrames::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -439,7 +415,6 @@ bool CMICmdCmdStackListFrames::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -452,12 +427,8 @@ CMICmdBase *CMICmdCmdStackListFrames::CreateSelf() { return new CMICmdCmdStackListFrames(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdStackListArguments constructor. // Type: Method. // Args: None. @@ -476,7 +447,6 @@ CMICmdCmdStackListArguments::CMICmdCmdStackListArguments() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdStackListArguments destructor. // Type: Overrideable. // Args: None. @@ -486,7 +456,6 @@ CMICmdCmdStackListArguments::CMICmdCmdStackListArguments() CMICmdCmdStackListArguments::~CMICmdCmdStackListArguments() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -505,7 +474,6 @@ bool CMICmdCmdStackListArguments::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -599,7 +567,6 @@ bool CMICmdCmdStackListArguments::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -633,7 +600,6 @@ bool CMICmdCmdStackListArguments::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -646,12 +612,8 @@ CMICmdBase *CMICmdCmdStackListArguments::CreateSelf() { return new CMICmdCmdStackListArguments(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdStackListLocals constructor. // Type: Method. // Args: None. @@ -669,7 +631,6 @@ CMICmdCmdStackListLocals::CMICmdCmdStackListLocals() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdStackListLocals destructor. // Type: Overrideable. // Args: None. @@ -679,7 +640,6 @@ CMICmdCmdStackListLocals::CMICmdCmdStackListLocals() CMICmdCmdStackListLocals::~CMICmdCmdStackListLocals() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -696,7 +656,6 @@ bool CMICmdCmdStackListLocals::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -771,7 +730,6 @@ bool CMICmdCmdStackListLocals::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -804,7 +762,6 @@ bool CMICmdCmdStackListLocals::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -817,12 +774,8 @@ CMICmdBase *CMICmdCmdStackListLocals::CreateSelf() { return new CMICmdCmdStackListLocals(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdStackListVariables constructor. // Type: Method. // Args: None. @@ -840,7 +793,6 @@ CMICmdCmdStackListVariables::CMICmdCmdStackListVariables() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdStackListVariables destructor. // Type: Overrideable. // Args: None. @@ -850,7 +802,6 @@ CMICmdCmdStackListVariables::CMICmdCmdStackListVariables() CMICmdCmdStackListVariables::~CMICmdCmdStackListVariables() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -867,7 +818,6 @@ bool CMICmdCmdStackListVariables::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -943,7 +893,6 @@ bool CMICmdCmdStackListVariables::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -976,7 +925,6 @@ bool CMICmdCmdStackListVariables::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -989,12 +937,8 @@ CMICmdBase *CMICmdCmdStackListVariables::CreateSelf() { return new CMICmdCmdStackListVariables(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdStackSelectFrame constructor. // Type: Method. // Args: None. @@ -1011,7 +955,6 @@ CMICmdCmdStackSelectFrame::CMICmdCmdStackSelectFrame() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdStackSelectFrame destructor. // Type: Overrideable. // Args: None. @@ -1021,7 +964,6 @@ CMICmdCmdStackSelectFrame::CMICmdCmdStackSelectFrame() CMICmdCmdStackSelectFrame::~CMICmdCmdStackSelectFrame() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -1037,7 +979,6 @@ bool CMICmdCmdStackSelectFrame::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -1067,7 +1008,6 @@ bool CMICmdCmdStackSelectFrame::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -1100,7 +1040,6 @@ bool CMICmdCmdStackSelectFrame::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. diff --git a/tools/lldb-mi/MICmdCmdStack.h b/tools/lldb-mi/MICmdCmdStack.h index 481186f5ddc5..04aeb5db0340 100644 --- a/tools/lldb-mi/MICmdCmdStack.h +++ b/tools/lldb-mi/MICmdCmdStack.h @@ -1,9 +1,8 @@ //===-- MICmdCmdStack.h -----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdCmdSupportInfo.cpp b/tools/lldb-mi/MICmdCmdSupportInfo.cpp index e36d398b0a05..e17f70a90472 100644 --- a/tools/lldb-mi/MICmdCmdSupportInfo.cpp +++ b/tools/lldb-mi/MICmdCmdSupportInfo.cpp @@ -1,9 +1,8 @@ -//===-- MICmdCmdSupportListInfo.cpp -----------------------------*- C++ -*-===// +//===-- MICmdCmdSupportInfo.cpp ---------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -18,7 +17,6 @@ #include "MICmnMIValueTuple.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdSupportInfoMiCmdQuery constructor. // Type: Method. // Args: None. @@ -35,7 +33,6 @@ CMICmdCmdSupportInfoMiCmdQuery::CMICmdCmdSupportInfoMiCmdQuery() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdSupportInfoMiCmdQuery destructor. // Type: Overrideable. // Args: None. @@ -45,7 +42,6 @@ CMICmdCmdSupportInfoMiCmdQuery::CMICmdCmdSupportInfoMiCmdQuery() CMICmdCmdSupportInfoMiCmdQuery::~CMICmdCmdSupportInfoMiCmdQuery() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -61,7 +57,6 @@ bool CMICmdCmdSupportInfoMiCmdQuery::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -86,7 +81,6 @@ bool CMICmdCmdSupportInfoMiCmdQuery::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -110,7 +104,6 @@ bool CMICmdCmdSupportInfoMiCmdQuery::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. diff --git a/tools/lldb-mi/MICmdCmdSupportInfo.h b/tools/lldb-mi/MICmdCmdSupportInfo.h index 7b503b1ee1ae..ba3e4a6c66a5 100644 --- a/tools/lldb-mi/MICmdCmdSupportInfo.h +++ b/tools/lldb-mi/MICmdCmdSupportInfo.h @@ -1,9 +1,8 @@ //===-- MICmdCmdSupportInfo.h -----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdCmdSupportList.cpp b/tools/lldb-mi/MICmdCmdSupportList.cpp index c3a9c9ad257a..e457e0101f4e 100644 --- a/tools/lldb-mi/MICmdCmdSupportList.cpp +++ b/tools/lldb-mi/MICmdCmdSupportList.cpp @@ -1,9 +1,8 @@ //===-- MICmdCmdSupportList.cpp ---------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -16,7 +15,6 @@ #include "MICmnMIValueList.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdSupportListFeatures constructor. // Type: Method. // Args: None. @@ -32,7 +30,6 @@ CMICmdCmdSupportListFeatures::CMICmdCmdSupportListFeatures() { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdSupportListFeatures destructor. // Type: Overrideable. // Args: None. @@ -42,7 +39,6 @@ CMICmdCmdSupportListFeatures::CMICmdCmdSupportListFeatures() { CMICmdCmdSupportListFeatures::~CMICmdCmdSupportListFeatures() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -60,7 +56,6 @@ bool CMICmdCmdSupportListFeatures::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -88,7 +83,6 @@ bool CMICmdCmdSupportListFeatures::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. diff --git a/tools/lldb-mi/MICmdCmdSupportList.h b/tools/lldb-mi/MICmdCmdSupportList.h index a9c27960bb9d..9e8a64bc11a1 100644 --- a/tools/lldb-mi/MICmdCmdSupportList.h +++ b/tools/lldb-mi/MICmdCmdSupportList.h @@ -1,9 +1,8 @@ //===-- MICmdCmdSupportList.h -----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdCmdSymbol.cpp b/tools/lldb-mi/MICmdCmdSymbol.cpp index 008e98d02e74..d57d1b008e59 100644 --- a/tools/lldb-mi/MICmdCmdSymbol.cpp +++ b/tools/lldb-mi/MICmdCmdSymbol.cpp @@ -1,9 +1,8 @@ //===-- MICmdCmdSymbol.cpp --------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -42,7 +41,6 @@ CreateMITuplePCLine(const uint32_t addr, const uint32_t line_number) { using namespace lldb; // For operator==(const SBAddress &, const SBAddress &). //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdSymbolListLines constructor. // Type: Method. // Args: None. @@ -59,7 +57,6 @@ CMICmdCmdSymbolListLines::CMICmdCmdSymbolListLines() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdSymbolListLines destructor. // Type: Overrideable. // Args: None. @@ -69,7 +66,6 @@ CMICmdCmdSymbolListLines::CMICmdCmdSymbolListLines() CMICmdCmdSymbolListLines::~CMICmdCmdSymbolListLines() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -85,7 +81,6 @@ bool CMICmdCmdSymbolListLines::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -150,7 +145,6 @@ bool CMICmdCmdSymbolListLines::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -170,7 +164,6 @@ bool CMICmdCmdSymbolListLines::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. diff --git a/tools/lldb-mi/MICmdCmdSymbol.h b/tools/lldb-mi/MICmdCmdSymbol.h index bd545345cf1b..839b0153a772 100644 --- a/tools/lldb-mi/MICmdCmdSymbol.h +++ b/tools/lldb-mi/MICmdCmdSymbol.h @@ -1,9 +1,8 @@ //===-- MICmdCmdSymbol.h ----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdCmdTarget.cpp b/tools/lldb-mi/MICmdCmdTarget.cpp index 0666fc4c60ec..18ce038b1685 100644 --- a/tools/lldb-mi/MICmdCmdTarget.cpp +++ b/tools/lldb-mi/MICmdCmdTarget.cpp @@ -1,9 +1,8 @@ //===-- MICmdCmdTarget.cpp --------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -26,7 +25,6 @@ #include "MICmnMIValueConst.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdTargetSelect constructor. // Type: Method. // Args: None. @@ -44,7 +42,6 @@ CMICmdCmdTargetSelect::CMICmdCmdTargetSelect() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdTargetSelect destructor. // Type: Overrideable. // Args: None. @@ -54,7 +51,6 @@ CMICmdCmdTargetSelect::CMICmdCmdTargetSelect() CMICmdCmdTargetSelect::~CMICmdCmdTargetSelect() = default; //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -72,7 +68,6 @@ bool CMICmdCmdTargetSelect::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -152,7 +147,6 @@ bool CMICmdCmdTargetSelect::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -188,7 +182,6 @@ bool CMICmdCmdTargetSelect::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -202,7 +195,6 @@ CMICmdBase *CMICmdCmdTargetSelect::CreateSelf() { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdTargetAttach constructor. // Type: Method. // Args: None. @@ -220,7 +212,6 @@ CMICmdCmdTargetAttach::CMICmdCmdTargetAttach() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdTargetAttach destructor. // Type: Overrideable. // Args: None. @@ -230,7 +221,6 @@ CMICmdCmdTargetAttach::CMICmdCmdTargetAttach() CMICmdCmdTargetAttach::~CMICmdCmdTargetAttach() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -251,7 +241,6 @@ bool CMICmdCmdTargetAttach::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -276,7 +265,7 @@ bool CMICmdCmdTargetAttach::Execute() { // If the current target is invalid, create one lldb::SBTarget target = rSessionInfo.GetTarget(); if (!target.IsValid()) { - target = rSessionInfo.GetDebugger().CreateTarget(NULL); + target = rSessionInfo.GetDebugger().CreateTarget(nullptr); if (!target.IsValid()) { SetError(CMIUtilString::Format(MIRSRC(IDS_CMD_ERR_INVALID_TARGET_CURRENT), m_cmdData.strMiCmd.c_str())); @@ -313,7 +302,6 @@ bool CMICmdCmdTargetAttach::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -349,7 +337,6 @@ bool CMICmdCmdTargetAttach::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -363,7 +350,6 @@ CMICmdBase *CMICmdCmdTargetAttach::CreateSelf() { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdTargetDetach constructor. // Type: Method. // Args: None. @@ -379,7 +365,6 @@ CMICmdCmdTargetDetach::CMICmdCmdTargetDetach() { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdTargetDetach destructor. // Type: Overrideable. // Args: None. @@ -389,7 +374,6 @@ CMICmdCmdTargetDetach::CMICmdCmdTargetDetach() { CMICmdCmdTargetDetach::~CMICmdCmdTargetDetach() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -402,7 +386,6 @@ CMICmdCmdTargetDetach::~CMICmdCmdTargetDetach() {} bool CMICmdCmdTargetDetach::ParseArgs() { return MIstatus::success; } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -434,7 +417,6 @@ bool CMICmdCmdTargetDetach::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -452,7 +434,6 @@ bool CMICmdCmdTargetDetach::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. diff --git a/tools/lldb-mi/MICmdCmdTarget.h b/tools/lldb-mi/MICmdCmdTarget.h index f0cad93bdbaf..5cb140fd68b9 100644 --- a/tools/lldb-mi/MICmdCmdTarget.h +++ b/tools/lldb-mi/MICmdCmdTarget.h @@ -1,9 +1,8 @@ //===-- MICmdCmdTarget.h ----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdCmdThread.cpp b/tools/lldb-mi/MICmdCmdThread.cpp index 32bdca5265bd..e0c74f925a9b 100644 --- a/tools/lldb-mi/MICmdCmdThread.cpp +++ b/tools/lldb-mi/MICmdCmdThread.cpp @@ -1,9 +1,8 @@ //===-- MICmdCmdThread.cpp --------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -22,7 +21,6 @@ #include "MICmnMIValueConst.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdThreadInfo constructor. // Type: Method. // Args: None. @@ -40,7 +38,6 @@ CMICmdCmdThreadInfo::CMICmdCmdThreadInfo() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdThreadInfo destructor. // Type: Overrideable. // Args: None. @@ -50,7 +47,6 @@ CMICmdCmdThreadInfo::CMICmdCmdThreadInfo() CMICmdCmdThreadInfo::~CMICmdCmdThreadInfo() { m_vecMIValueTuple.clear(); } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -67,7 +63,6 @@ bool CMICmdCmdThreadInfo::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -136,7 +131,6 @@ bool CMICmdCmdThreadInfo::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -204,7 +198,6 @@ bool CMICmdCmdThreadInfo::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. diff --git a/tools/lldb-mi/MICmdCmdThread.h b/tools/lldb-mi/MICmdCmdThread.h index 7635e9fd9652..413e293447ac 100644 --- a/tools/lldb-mi/MICmdCmdThread.h +++ b/tools/lldb-mi/MICmdCmdThread.h @@ -1,9 +1,8 @@ //===-- MICmdCmdThread.h ----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdCmdTrace.cpp b/tools/lldb-mi/MICmdCmdTrace.cpp index c98ede225faf..1daa18010c97 100644 --- a/tools/lldb-mi/MICmdCmdTrace.cpp +++ b/tools/lldb-mi/MICmdCmdTrace.cpp @@ -1,9 +1,8 @@ //===-- MICmdCmdTrace.cpp ---------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -15,7 +14,6 @@ #include "MICmnMIValueConst.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdTraceStatus constructor. // Type: Method. // Args: None. @@ -31,7 +29,6 @@ CMICmdCmdTraceStatus::CMICmdCmdTraceStatus() { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdTraceStatus destructor. // Type: Overrideable. // Args: None. @@ -41,7 +38,6 @@ CMICmdCmdTraceStatus::CMICmdCmdTraceStatus() { CMICmdCmdTraceStatus::~CMICmdCmdTraceStatus() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -58,7 +54,6 @@ bool CMICmdCmdTraceStatus::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -80,7 +75,6 @@ bool CMICmdCmdTraceStatus::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. diff --git a/tools/lldb-mi/MICmdCmdTrace.h b/tools/lldb-mi/MICmdCmdTrace.h index b6cb3aea5d32..8796de55b958 100644 --- a/tools/lldb-mi/MICmdCmdTrace.h +++ b/tools/lldb-mi/MICmdCmdTrace.h @@ -1,9 +1,8 @@ //===-- MICmdCmdTrace.h -----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdCmdVar.cpp b/tools/lldb-mi/MICmdCmdVar.cpp index 85f14ec29b93..3063b1b464dc 100644 --- a/tools/lldb-mi/MICmdCmdVar.cpp +++ b/tools/lldb-mi/MICmdCmdVar.cpp @@ -1,9 +1,8 @@ //===-- MICmdCmdVar.cpp -----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -41,7 +40,6 @@ #include <algorithm> //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdVarCreate constructor. // Type: Method. // Args: None. @@ -61,7 +59,6 @@ CMICmdCmdVarCreate::CMICmdCmdVarCreate() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdVarCreate destructor. // Type: Overrideable. // Args: None. @@ -71,7 +68,6 @@ CMICmdCmdVarCreate::CMICmdCmdVarCreate() CMICmdCmdVarCreate::~CMICmdCmdVarCreate() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -90,7 +86,6 @@ bool CMICmdCmdVarCreate::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -212,7 +207,6 @@ bool CMICmdCmdVarCreate::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -265,7 +259,6 @@ bool CMICmdCmdVarCreate::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -279,7 +272,6 @@ CMICmdBase *CMICmdCmdVarCreate::CreateSelf() { } //++ -//------------------------------------------------------------------------------------ // Details: Complete SBValue object and its children to get // SBValue::GetValueDidChange // work. @@ -305,12 +297,8 @@ void CMICmdCmdVarCreate::CompleteSBValue(lldb::SBValue &vrwValue) { } } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdVarUpdate constructor. // Type: Method. // Args: None. @@ -328,7 +316,6 @@ CMICmdCmdVarUpdate::CMICmdCmdVarUpdate() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdVarUpdate destructor. // Type: Overrideable. // Args: None. @@ -338,7 +325,6 @@ CMICmdCmdVarUpdate::CMICmdCmdVarUpdate() CMICmdCmdVarUpdate::~CMICmdCmdVarUpdate() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -356,7 +342,6 @@ bool CMICmdCmdVarUpdate::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -409,7 +394,6 @@ bool CMICmdCmdVarUpdate::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -442,7 +426,6 @@ bool CMICmdCmdVarUpdate::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -456,7 +439,6 @@ CMICmdBase *CMICmdCmdVarUpdate::CreateSelf() { } //++ -//------------------------------------------------------------------------------------ // Details: Form the MI response for multiple variables. // Type: Method. // Args: vrStrVarName - (R) Session var object's name. @@ -492,7 +474,6 @@ void CMICmdCmdVarUpdate::MIFormResponse(const CMIUtilString &vrStrVarName, } //++ -//------------------------------------------------------------------------------------ // Details: Determine if the var object was changed. // Type: Method. // Args: vrVarObj - (R) Session var object to examine. @@ -528,12 +509,8 @@ bool CMICmdCmdVarUpdate::ExamineSBValueForChange(lldb::SBValue &vrwValue, return MIstatus::success; } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdVarDelete constructor. // Type: Method. // Args: None. @@ -549,7 +526,6 @@ CMICmdCmdVarDelete::CMICmdCmdVarDelete() : m_constStrArgName("name") { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -565,7 +541,6 @@ bool CMICmdCmdVarDelete::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdVarDelete destructor. // Type: Overrideable. // Args: None. @@ -575,7 +550,6 @@ bool CMICmdCmdVarDelete::ParseArgs() { CMICmdCmdVarDelete::~CMICmdCmdVarDelete() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -596,7 +570,6 @@ bool CMICmdCmdVarDelete::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -615,7 +588,6 @@ bool CMICmdCmdVarDelete::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -628,12 +600,8 @@ CMICmdBase *CMICmdCmdVarDelete::CreateSelf() { return new CMICmdCmdVarDelete(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdVarAssign constructor. // Type: Method. // Args: None. @@ -651,7 +619,6 @@ CMICmdCmdVarAssign::CMICmdCmdVarAssign() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdVarAssign destructor. // Type: Overrideable. // Args: None. @@ -661,7 +628,6 @@ CMICmdCmdVarAssign::CMICmdCmdVarAssign() CMICmdCmdVarAssign::~CMICmdCmdVarAssign() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -678,7 +644,6 @@ bool CMICmdCmdVarAssign::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -716,7 +681,6 @@ bool CMICmdCmdVarAssign::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -752,7 +716,6 @@ bool CMICmdCmdVarAssign::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -765,12 +728,8 @@ CMICmdBase *CMICmdCmdVarAssign::CreateSelf() { return new CMICmdCmdVarAssign(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdVarSetFormat constructor. // Type: Method. // Args: None. @@ -787,7 +746,6 @@ CMICmdCmdVarSetFormat::CMICmdCmdVarSetFormat() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdVarSetFormat destructor. // Type: Overrideable. // Args: None. @@ -797,7 +755,6 @@ CMICmdCmdVarSetFormat::CMICmdCmdVarSetFormat() CMICmdCmdVarSetFormat::~CMICmdCmdVarSetFormat() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -814,7 +771,6 @@ bool CMICmdCmdVarSetFormat::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -855,7 +811,6 @@ bool CMICmdCmdVarSetFormat::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -898,7 +853,6 @@ bool CMICmdCmdVarSetFormat::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -911,12 +865,8 @@ CMICmdBase *CMICmdCmdVarSetFormat::CreateSelf() { return new CMICmdCmdVarSetFormat(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdVarListChildren constructor. // Type: Method. // Args: None. @@ -935,7 +885,6 @@ CMICmdCmdVarListChildren::CMICmdCmdVarListChildren() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdVarListChildren destructor. // Type: Overrideable. // Args: None. @@ -945,7 +894,6 @@ CMICmdCmdVarListChildren::CMICmdCmdVarListChildren() CMICmdCmdVarListChildren::~CMICmdCmdVarListChildren() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -965,7 +913,6 @@ bool CMICmdCmdVarListChildren::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -1078,7 +1025,6 @@ bool CMICmdCmdVarListChildren::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -1120,7 +1066,6 @@ bool CMICmdCmdVarListChildren::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -1133,12 +1078,8 @@ CMICmdBase *CMICmdCmdVarListChildren::CreateSelf() { return new CMICmdCmdVarListChildren(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdVarEvaluateExpression constructor. // Type: Method. // Args: None. @@ -1156,7 +1097,6 @@ CMICmdCmdVarEvaluateExpression::CMICmdCmdVarEvaluateExpression() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdVarEvaluateExpression destructor. // Type: Overrideable. // Args: None. @@ -1166,7 +1106,6 @@ CMICmdCmdVarEvaluateExpression::CMICmdCmdVarEvaluateExpression() CMICmdCmdVarEvaluateExpression::~CMICmdCmdVarEvaluateExpression() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -1185,7 +1124,6 @@ bool CMICmdCmdVarEvaluateExpression::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -1220,7 +1158,6 @@ bool CMICmdCmdVarEvaluateExpression::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -1253,7 +1190,6 @@ bool CMICmdCmdVarEvaluateExpression::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -1266,12 +1202,8 @@ CMICmdBase *CMICmdCmdVarEvaluateExpression::CreateSelf() { return new CMICmdCmdVarEvaluateExpression(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdVarInfoPathExpression constructor. // Type: Method. // Args: None. @@ -1288,7 +1220,6 @@ CMICmdCmdVarInfoPathExpression::CMICmdCmdVarInfoPathExpression() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdVarInfoPathExpression destructor. // Type: Overrideable. // Args: None. @@ -1298,7 +1229,6 @@ CMICmdCmdVarInfoPathExpression::CMICmdCmdVarInfoPathExpression() CMICmdCmdVarInfoPathExpression::~CMICmdCmdVarInfoPathExpression() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -1314,7 +1244,6 @@ bool CMICmdCmdVarInfoPathExpression::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -1385,7 +1314,6 @@ bool CMICmdCmdVarInfoPathExpression::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -1417,7 +1345,6 @@ bool CMICmdCmdVarInfoPathExpression::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. @@ -1430,12 +1357,8 @@ CMICmdBase *CMICmdCmdVarInfoPathExpression::CreateSelf() { return new CMICmdCmdVarInfoPathExpression(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdVarShowAttributes constructor. // Type: Method. // Args: None. @@ -1452,7 +1375,6 @@ CMICmdCmdVarShowAttributes::CMICmdCmdVarShowAttributes() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmdCmdVarShowAttributes destructor. // Type: Overrideable. // Args: None. @@ -1462,7 +1384,6 @@ CMICmdCmdVarShowAttributes::CMICmdCmdVarShowAttributes() CMICmdCmdVarShowAttributes::~CMICmdCmdVarShowAttributes() {} //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The parses the command line // options // arguments to extract values for each of those arguments. @@ -1478,7 +1399,6 @@ bool CMICmdCmdVarShowAttributes::ParseArgs() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command does work in this // function. // The command is likely to communicate with the LLDB SBDebugger in @@ -1505,7 +1425,6 @@ bool CMICmdCmdVarShowAttributes::Execute() { } //++ -//------------------------------------------------------------------------------------ // Details: The invoker requires this function. The command prepares a MI Record // Result // for the work carried out in the Execute(). @@ -1528,7 +1447,6 @@ bool CMICmdCmdVarShowAttributes::Acknowledge() { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdFactory when registering *this command. The // factory // calls this function to create an instance of *this command. diff --git a/tools/lldb-mi/MICmdCmdVar.h b/tools/lldb-mi/MICmdCmdVar.h index 7bf583bfd364..cdd036688ca3 100644 --- a/tools/lldb-mi/MICmdCmdVar.h +++ b/tools/lldb-mi/MICmdCmdVar.h @@ -1,9 +1,8 @@ //===-- MICmdCmdVar.h -------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdCommands.cpp b/tools/lldb-mi/MICmdCommands.cpp index 42983c428879..cffc50a9ba6d 100644 --- a/tools/lldb-mi/MICmdCommands.cpp +++ b/tools/lldb-mi/MICmdCommands.cpp @@ -1,9 +1,8 @@ //===-- MICmdCommands.cpp ---------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -46,7 +45,6 @@ template <typename T> static bool Register(); } //++ -//------------------------------------------------------------------------------------ // Details: Command to command factory registration function. // Type: Template function. // Args: typename T - A command type class. @@ -62,7 +60,6 @@ template <typename T> static bool MICmnCommands::Register() { } //++ -//------------------------------------------------------------------------------------ // Details: Register commands with MI command factory // Type: Function. // Args: None. diff --git a/tools/lldb-mi/MICmdCommands.h b/tools/lldb-mi/MICmdCommands.h index c3f752857b84..f2e3bfde7603 100644 --- a/tools/lldb-mi/MICmdCommands.h +++ b/tools/lldb-mi/MICmdCommands.h @@ -1,9 +1,8 @@ //===-- MICmdCommands.h -----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdData.cpp b/tools/lldb-mi/MICmdData.cpp index faafaf52483d..6d0b679b8571 100644 --- a/tools/lldb-mi/MICmdData.cpp +++ b/tools/lldb-mi/MICmdData.cpp @@ -1,9 +1,8 @@ //===-- MICmdData.cpp -------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdData.h b/tools/lldb-mi/MICmdData.h index b0d52b5bf809..3e46b54d835d 100644 --- a/tools/lldb-mi/MICmdData.h +++ b/tools/lldb-mi/MICmdData.h @@ -1,9 +1,8 @@ //===-- MICmdData.h ---------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdFactory.cpp b/tools/lldb-mi/MICmdFactory.cpp index ad4283e50215..30995835c688 100644 --- a/tools/lldb-mi/MICmdFactory.cpp +++ b/tools/lldb-mi/MICmdFactory.cpp @@ -1,9 +1,8 @@ //===-- MICmdFactory.cpp ----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -15,7 +14,6 @@ #include "MICmnResources.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdFactory constructor. // Type: Method. // Args: None. @@ -25,7 +23,6 @@ CMICmdFactory::CMICmdFactory() {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdFactory destructor. // Type: Overridable. // Args: None. @@ -35,7 +32,6 @@ CMICmdFactory::CMICmdFactory() {} CMICmdFactory::~CMICmdFactory() { Shutdown(); } //++ -//------------------------------------------------------------------------------------ // Details: Initialize resources for *this Command factory. // Type: Method. // Args: None. @@ -57,7 +53,6 @@ bool CMICmdFactory::Initialize() { } //++ -//------------------------------------------------------------------------------------ // Details: Release resources for *this Command Factory. // Type: Method. // Args: None. @@ -80,7 +75,6 @@ bool CMICmdFactory::Shutdown() { } //++ -//------------------------------------------------------------------------------------ // Details: Register a command's creator function with the command identifier // the MI // command name i.e. 'file-exec-and-symbols'. @@ -117,7 +111,6 @@ bool CMICmdFactory::CmdRegister(const CMIUtilString &vMiCmd, } //++ -//------------------------------------------------------------------------------------ // Details: Check a command is already registered. // Type: Method. // Args: vMiCmd - (R) Command's name, the MI command. @@ -132,7 +125,6 @@ bool CMICmdFactory::HaveAlready(const CMIUtilString &vMiCmd) const { } //++ -//------------------------------------------------------------------------------------ // Details: Check a command's name is valid: // - name is not empty // - name does not have spaces @@ -158,7 +150,6 @@ bool CMICmdFactory::IsValid(const CMIUtilString &vMiCmd) const { } //++ -//------------------------------------------------------------------------------------ // Details: Check a command is already registered. // Type: Method. // Args: vMiCmd - (R) Command's name, the MI command. @@ -171,7 +162,6 @@ bool CMICmdFactory::CmdExist(const CMIUtilString &vMiCmd) const { } //++ -//------------------------------------------------------------------------------------ // Details: Create a command given the specified MI command name. The command // data object // contains the options for the command. diff --git a/tools/lldb-mi/MICmdFactory.h b/tools/lldb-mi/MICmdFactory.h index 6d8a759ec67d..19987c281ad0 100644 --- a/tools/lldb-mi/MICmdFactory.h +++ b/tools/lldb-mi/MICmdFactory.h @@ -1,9 +1,8 @@ //===-- MICmdFactory.h ------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdInterpreter.cpp b/tools/lldb-mi/MICmdInterpreter.cpp index 8dd99ed5e670..9e37ac2d6108 100644 --- a/tools/lldb-mi/MICmdInterpreter.cpp +++ b/tools/lldb-mi/MICmdInterpreter.cpp @@ -1,9 +1,8 @@ //===-- MICmdInterpreter.cpp ------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -12,7 +11,6 @@ #include "MICmdFactory.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdInterpreter constructor. // Type: Method. // Args: None. @@ -23,7 +21,6 @@ CMICmdInterpreter::CMICmdInterpreter() : m_rCmdFactory(CMICmdFactory::Instance()) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdInterpreter destructor. // Type: Overridable. // Args: None. @@ -33,7 +30,6 @@ CMICmdInterpreter::CMICmdInterpreter() CMICmdInterpreter::~CMICmdInterpreter() { Shutdown(); } //++ -//------------------------------------------------------------------------------------ // Details: Initialize resources for *this Command Interpreter. // Type: Method. // Args: None. @@ -53,7 +49,6 @@ bool CMICmdInterpreter::Initialize() { } //++ -//------------------------------------------------------------------------------------ // Details: Release resources for *this Command Interpreter. // Type: Method. // Args: None. @@ -74,7 +69,6 @@ bool CMICmdInterpreter::Shutdown() { } //++ -//------------------------------------------------------------------------------------ // Details: Establish whether the text data is an MI format type command. // Type: Method. // Args: vTextLine - (R) Text data to interpret. @@ -123,7 +117,6 @@ bool CMICmdInterpreter::ValidateIsMi(const CMIUtilString &vTextLine, } //++ -//------------------------------------------------------------------------------------ // Details: Establish whether the command name entered on the stdin stream is // recognised by // the MI driver. @@ -138,7 +131,6 @@ bool CMICmdInterpreter::HasCmdFactoryGotMiCmd(const SMICmdData &vCmd) const { } //++ -//------------------------------------------------------------------------------------ // Details: Does the command entered match the criteria for a MI command format. // The format to validate against is 'nn-' where there can be 1 to n // digits. @@ -175,7 +167,6 @@ bool CMICmdInterpreter::MiHasCmdTokenEndingHyphen( } //++ -//------------------------------------------------------------------------------------ // Details: Does the command entered match the criteria for a MI command format. // The format to validate against is 'nnA' where there can be 1 to n // digits. @@ -211,7 +202,6 @@ bool CMICmdInterpreter::MiHasCmdTokenEndingAlpha( } //++ -//------------------------------------------------------------------------------------ // Details: Does the command entered match the criteria for a MI command format. // Is the command token present before the hyphen? // Type: Method. @@ -225,7 +215,6 @@ bool CMICmdInterpreter::MiHasCmdTokenPresent(const CMIUtilString &vTextLine) { } //++ -//------------------------------------------------------------------------------------ // Details: Does the command name entered match the criteria for a MI command // format. // Is a recognised command present? The command name is entered into @@ -288,7 +277,6 @@ bool CMICmdInterpreter::MiHasCmd(const CMIUtilString &vTextLine) { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the just entered new command from stdin. It contains the // command // name, number and any options. diff --git a/tools/lldb-mi/MICmdInterpreter.h b/tools/lldb-mi/MICmdInterpreter.h index 948e7515d526..100d309ac772 100644 --- a/tools/lldb-mi/MICmdInterpreter.h +++ b/tools/lldb-mi/MICmdInterpreter.h @@ -1,9 +1,8 @@ //===-- MICmdInterpreter.h --------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdInvoker.cpp b/tools/lldb-mi/MICmdInvoker.cpp index ea7116dd688b..f4150a20ccd9 100644 --- a/tools/lldb-mi/MICmdInvoker.cpp +++ b/tools/lldb-mi/MICmdInvoker.cpp @@ -1,9 +1,8 @@ //===-- MICmdInvoker.cpp ----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -16,7 +15,6 @@ #include "MIDriver.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdInvoker constructor. // Type: Method. // Args: None. @@ -26,7 +24,6 @@ CMICmdInvoker::CMICmdInvoker() : m_rStreamOut(CMICmnStreamStdout::Instance()) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdInvoker destructor. // Type: Overridable. // Args: None. @@ -36,7 +33,6 @@ CMICmdInvoker::CMICmdInvoker() : m_rStreamOut(CMICmnStreamStdout::Instance()) {} CMICmdInvoker::~CMICmdInvoker() { Shutdown(); } //++ -//------------------------------------------------------------------------------------ // Details: Initialize resources for *this Command Invoker. // Type: Method. // Args: None. @@ -56,7 +52,6 @@ bool CMICmdInvoker::Initialize() { } //++ -//------------------------------------------------------------------------------------ // Details: Release resources for *this Stdin stream. // Type: Method. // Args: None. @@ -79,7 +74,6 @@ bool CMICmdInvoker::Shutdown() { } //++ -//------------------------------------------------------------------------------------ // Details: Empty the map of invoked commands doing work. Command objects are // deleted too. // Type: Method. @@ -105,7 +99,6 @@ void CMICmdInvoker::CmdDeleteAll() { } //++ -//------------------------------------------------------------------------------------ // Details: Remove from the map of invoked commands doing work a command that // has finished // its work. The command object is deleted too. @@ -139,7 +132,6 @@ bool CMICmdInvoker::CmdDelete(const MIuint vId, } //++ -//------------------------------------------------------------------------------------ // Details: Add to the map of invoked commands doing work a command that is // about to // start to do work. @@ -166,7 +158,6 @@ bool CMICmdInvoker::CmdAdd(const CMICmdBase &vCmd) { } //++ -//------------------------------------------------------------------------------------ // Details: Having previously had the potential command validated and found // valid now // get the command executed. @@ -213,7 +204,6 @@ bool CMICmdInvoker::CmdExecute(CMICmdBase &vCmd) { } //++ -//------------------------------------------------------------------------------------ // Details: Called when a command has finished its Execution() work either // synchronously // because the command executed was the type a non event type or @@ -270,7 +260,6 @@ bool CMICmdInvoker::CmdExecuteFinished(CMICmdBase &vCmd) { } //++ -//------------------------------------------------------------------------------------ // Details: If the MI Driver is not operating via a client i.e. Eclipse check // the command // on failure suggests the application exits. A command can be such @@ -291,7 +280,6 @@ void CMICmdInvoker::CmdCauseAppExit(const CMICmdBase &vCmd) const { } //++ -//------------------------------------------------------------------------------------ // Details: Write to stdout and the Log file the command's MI formatted result. // Type: vCmdData - (R) A command's information. // Return: MIstatus::success - Functionality succeeded. @@ -313,7 +301,6 @@ bool CMICmdInvoker::CmdStdout(const SMICmdData &vCmdData) const { } //++ -//------------------------------------------------------------------------------------ // Details: Required by the CMICmdMgr::ICmdDeleteCallback. *this object is // registered // with the Command Manager to receive callbacks when a command is diff --git a/tools/lldb-mi/MICmdInvoker.h b/tools/lldb-mi/MICmdInvoker.h index 40c4625f7ab1..5db8d36ad26e 100644 --- a/tools/lldb-mi/MICmdInvoker.h +++ b/tools/lldb-mi/MICmdInvoker.h @@ -1,9 +1,8 @@ //===-- MICmdInvoker.h ------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdMgr.cpp b/tools/lldb-mi/MICmdMgr.cpp index 8daa38c1af23..453ffedbd33d 100644 --- a/tools/lldb-mi/MICmdMgr.cpp +++ b/tools/lldb-mi/MICmdMgr.cpp @@ -1,9 +1,8 @@ //===-- MICmdMgr.cpp --------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -19,7 +18,6 @@ #include "MIUtilSingletonHelper.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmdMgr constructor. // Type: Method. // Args: None. @@ -32,7 +30,6 @@ CMICmdMgr::CMICmdMgr() m_invoker(CMICmdInvoker::Instance()) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmdMgr destructor. // Type: Overridable. // Args: None. @@ -42,7 +39,6 @@ CMICmdMgr::CMICmdMgr() CMICmdMgr::~CMICmdMgr() { Shutdown(); } //++ -//------------------------------------------------------------------------------------ // Details: Initialize resources for *this Command Manager. // Type: Method. // Args: None. @@ -91,7 +87,6 @@ bool CMICmdMgr::Initialize() { } //++ -//------------------------------------------------------------------------------------ // Details: Release resources for *this Command Manager. // Type: Method. // Args: None. @@ -148,7 +143,6 @@ bool CMICmdMgr::Shutdown() { } //++ -//------------------------------------------------------------------------------------ // Details: Establish whether the text data is an MI format type command. // Type: Method. // Args: vTextLine - (R) Text data to interpret. @@ -168,7 +162,6 @@ bool CMICmdMgr::CmdInterpret(const CMIUtilString &vTextLine, bool &vwbYesValid, } //++ -//------------------------------------------------------------------------------------ // Details: Having previously had the potential command validated and found // valid now // get the command executed. @@ -210,7 +203,6 @@ bool CMICmdMgr::CmdExecute(const SMICmdData &vCmdData) { } //++ -//------------------------------------------------------------------------------------ // Details: Iterate all interested clients and tell them a command is being // deleted. // Type: Method. @@ -229,7 +221,6 @@ bool CMICmdMgr::CmdDelete(SMICmdData vCmdData) { } //++ -//------------------------------------------------------------------------------------ // Details: Register an object to be called when a command object is deleted. // Type: Method. // Args: vObject - (R) A new interested client. @@ -243,7 +234,6 @@ bool CMICmdMgr::CmdRegisterForDeleteNotification( } //++ -//------------------------------------------------------------------------------------ // Details: Unregister an object from being called when a command object is // deleted. // Type: Method. diff --git a/tools/lldb-mi/MICmdMgr.h b/tools/lldb-mi/MICmdMgr.h index 1e58b7532945..307ef897c58d 100644 --- a/tools/lldb-mi/MICmdMgr.h +++ b/tools/lldb-mi/MICmdMgr.h @@ -1,9 +1,8 @@ //===-- MICmdMgr.h ----------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmdMgrSetCmdDeleteCallback.cpp b/tools/lldb-mi/MICmdMgrSetCmdDeleteCallback.cpp index 1d21a1baaaf1..d6146b8d276d 100644 --- a/tools/lldb-mi/MICmdMgrSetCmdDeleteCallback.cpp +++ b/tools/lldb-mi/MICmdMgrSetCmdDeleteCallback.cpp @@ -1,9 +1,8 @@ //===-- MICmdMgrSetCmdDeleteCallback.cpp ------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -13,7 +12,6 @@ namespace CMICmdMgrSetCmdDeleteCallback { //++ -//------------------------------------------------------------------------------------ // Details: CSetClients constructor. // Type: Method. // Args: None. @@ -23,7 +21,6 @@ namespace CMICmdMgrSetCmdDeleteCallback { CSetClients::CSetClients() : m_bClientUnregistered(false) {} //++ -//------------------------------------------------------------------------------------ // Details: CSetClients destructor. // Type: Method. // Args: None. @@ -33,7 +30,6 @@ CSetClients::CSetClients() : m_bClientUnregistered(false) {} CSetClients::~CSetClients() {} //++ -//------------------------------------------------------------------------------------ // Details: Register an object to be called when a command object is deleted. // Type: Method. // Args: vObject - (R) A new interested client. @@ -48,7 +44,6 @@ bool CSetClients::Register(ICallback &vObject) { } //++ -//------------------------------------------------------------------------------------ // Details: Unregister an object from being called when a command object is // deleted. // Type: Method. @@ -65,7 +60,6 @@ bool CSetClients::Unregister(ICallback &vObject) { } //++ -//------------------------------------------------------------------------------------ // Details: Iterate all interested clients and tell them a command is being // deleted. // Type: Method. diff --git a/tools/lldb-mi/MICmdMgrSetCmdDeleteCallback.h b/tools/lldb-mi/MICmdMgrSetCmdDeleteCallback.h index 0363831b7658..30df5e9cd424 100644 --- a/tools/lldb-mi/MICmdMgrSetCmdDeleteCallback.h +++ b/tools/lldb-mi/MICmdMgrSetCmdDeleteCallback.h @@ -1,9 +1,8 @@ //===-- MICmdMgrSetCmdDeleteCallback.h --------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// //-- diff --git a/tools/lldb-mi/MICmnBase.cpp b/tools/lldb-mi/MICmnBase.cpp index 7f82c6120e1a..9d87064aa64c 100644 --- a/tools/lldb-mi/MICmnBase.cpp +++ b/tools/lldb-mi/MICmnBase.cpp @@ -1,9 +1,8 @@ //===-- MICmnBase.cpp -------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -16,7 +15,6 @@ #include "MICmnStreamStderr.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmnBase constructor. // Type: Method. // Args: None. @@ -28,17 +26,15 @@ CMICmnBase::CMICmnBase() m_pLog(&CMICmnLog::Instance()), m_clientUsageRefCnt(0) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmnBase destructor. // Type: Overrideable. // Args: None. // Return: None. // Throws: None. //-- -CMICmnBase::~CMICmnBase() { m_pLog = NULL; } +CMICmnBase::~CMICmnBase() { m_pLog = nullptr; } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve whether *this object has an error description set. // Type: Method. // Args: None. @@ -50,7 +46,6 @@ bool CMICmnBase::HaveErrorDescription() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve MI's last error condition. // Type: Method. // Args: None. @@ -62,7 +57,6 @@ const CMIUtilString &CMICmnBase::GetErrorDescription() const { } //++ -//------------------------------------------------------------------------------------ // Details: Set MI's error condition description. This may be accessed by // clients and // seen by users. Message is available to the client using the server @@ -82,7 +76,6 @@ void CMICmnBase::SetErrorDescription(const CMIUtilString &vrTxt) const { } //++ -//------------------------------------------------------------------------------------ // Details: Set MI's error condition description. This may be accessed by // clients and // seen by users. Message is available to the client using the server @@ -98,7 +91,6 @@ void CMICmnBase::SetErrorDescriptionNoLog(const CMIUtilString &vrTxt) const { } //++ -//------------------------------------------------------------------------------------ // Details: Clear MI's error condition description. // Type: Method. // Args: None. @@ -110,7 +102,6 @@ void CMICmnBase::ClrErrorDescription() const { } //++ -//------------------------------------------------------------------------------------ // Details: Set MI's error condition description. This may be accessed by // clients and // seen by users. Message is available to the client using the server diff --git a/tools/lldb-mi/MICmnBase.h b/tools/lldb-mi/MICmnBase.h index 2b604638b2dc..368e912b6d8a 100644 --- a/tools/lldb-mi/MICmnBase.h +++ b/tools/lldb-mi/MICmnBase.h @@ -1,9 +1,8 @@ //===-- MICmnBase.h ---------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnConfig.h b/tools/lldb-mi/MICmnConfig.h index 78793c7b020c..9dd57922cecf 100644 --- a/tools/lldb-mi/MICmnConfig.h +++ b/tools/lldb-mi/MICmnConfig.h @@ -1,9 +1,8 @@ //===-- MICmnConfig.h -------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// //-- diff --git a/tools/lldb-mi/MICmnLLDBBroadcaster.cpp b/tools/lldb-mi/MICmnLLDBBroadcaster.cpp index 8840261eaa57..554ec1f7e9fd 100644 --- a/tools/lldb-mi/MICmnLLDBBroadcaster.cpp +++ b/tools/lldb-mi/MICmnLLDBBroadcaster.cpp @@ -1,9 +1,8 @@ //===-- MICmnLLDBBroadcaster.cpp --------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -11,7 +10,6 @@ #include "MICmnLLDBBroadcaster.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLLDBBroadcaster constructor. // Type: Method. // Args: None. @@ -22,7 +20,6 @@ CMICmnLLDBBroadcaster::CMICmnLLDBBroadcaster() : lldb::SBBroadcaster("MI driver") {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLLDBBroadcaster destructor. // Type: Overridable. // Args: None. @@ -32,7 +29,6 @@ CMICmnLLDBBroadcaster::CMICmnLLDBBroadcaster() CMICmnLLDBBroadcaster::~CMICmnLLDBBroadcaster() { Shutdown(); } //++ -//------------------------------------------------------------------------------------ // Details: Initialize resources for *this broadcaster object. // Type: Method. // Args: None. @@ -52,7 +48,6 @@ bool CMICmnLLDBBroadcaster::Initialize() { } //++ -//------------------------------------------------------------------------------------ // Details: Release resources for *this broadcaster object. // Type: Method. // Args: None. diff --git a/tools/lldb-mi/MICmnLLDBBroadcaster.h b/tools/lldb-mi/MICmnLLDBBroadcaster.h index dcf196f16dc8..326b6769fcb7 100644 --- a/tools/lldb-mi/MICmnLLDBBroadcaster.h +++ b/tools/lldb-mi/MICmnLLDBBroadcaster.h @@ -1,9 +1,8 @@ //===-- MICmnLLDBBroadcaster.h ----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnLLDBDebugSessionInfo.cpp b/tools/lldb-mi/MICmnLLDBDebugSessionInfo.cpp index f7f43f001b7b..5ec2c588e201 100644 --- a/tools/lldb-mi/MICmnLLDBDebugSessionInfo.cpp +++ b/tools/lldb-mi/MICmnLLDBDebugSessionInfo.cpp @@ -1,9 +1,8 @@ //===-- MICmnLLDBDebugSessionInfo.cpp ---------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -30,7 +29,6 @@ #include "Platform.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLLDBDebugSessionInfo constructor. // Type: Method. // Args: None. @@ -47,7 +45,6 @@ CMICmnLLDBDebugSessionInfo::CMICmnLLDBDebugSessionInfo() m_constStrPrintAggregateFieldNames("Print AggregateFieldNames") {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLLDBDebugSessionInfo destructor. // Type: Overridable. // Args: None. @@ -57,7 +54,6 @@ CMICmnLLDBDebugSessionInfo::CMICmnLLDBDebugSessionInfo() CMICmnLLDBDebugSessionInfo::~CMICmnLLDBDebugSessionInfo() { Shutdown(); } //++ -//------------------------------------------------------------------------------------ // Details: Initialize resources for *this object. // Type: Method. // Args: None. @@ -80,7 +76,6 @@ bool CMICmnLLDBDebugSessionInfo::Initialize() { } //++ -//------------------------------------------------------------------------------------ // Details: Release resources for *this object. // Type: Method. // Args: None. @@ -107,7 +102,6 @@ bool CMICmnLLDBDebugSessionInfo::Shutdown() { } //++ -//------------------------------------------------------------------------------------ // Details: Command instances can create and share data between other instances // of commands. // Data can also be assigned by a command and retrieved by LLDB event @@ -129,7 +123,6 @@ void CMICmnLLDBDebugSessionInfo::SharedDataDestroy() { } //++ -//------------------------------------------------------------------------------------ // Details: Record information about a LLDB break point so that is can be // recalled in other // commands or LLDB event handling functions. @@ -149,7 +142,6 @@ bool CMICmnLLDBDebugSessionInfo::RecordBrkPtInfo( } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve information about a LLDB break point previous recorded // either by // commands or LLDB event handling functions. @@ -173,7 +165,6 @@ bool CMICmnLLDBDebugSessionInfo::RecordBrkPtInfoGet( } //++ -//------------------------------------------------------------------------------------ // Details: Delete information about a specific LLDB break point object. This // function // should be called when a LLDB break point is deleted. @@ -195,7 +186,6 @@ bool CMICmnLLDBDebugSessionInfo::RecordBrkPtInfoDelete(const MIuint vnBrkPtId) { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the specified thread's frame information. // Type: Method. // Args: vCmdData - (R) A command's information. @@ -242,7 +232,6 @@ bool CMICmnLLDBDebugSessionInfo::GetThreadFrames( } //++ -//------------------------------------------------------------------------------------ // Details: Return the resolved file's path for the given file. // Type: Method. // Args: vCmdData - (R) A command's information. @@ -273,7 +262,6 @@ bool CMICmnLLDBDebugSessionInfo::ResolvePath(const SMICmdData &vCmdData, } //++ -//------------------------------------------------------------------------------------ // Details: Return the resolved file's path for the given file. // Type: Method. // Args: vstrUnknown - (R) String assigned to path when resolved path @@ -321,7 +309,6 @@ bool CMICmnLLDBDebugSessionInfo::ResolvePath(const CMIUtilString &vstrUnknown, } //++ -//------------------------------------------------------------------------------------ // Details: Determine the given file path exists or not. // Type: Method. // Args: vPath - (R) File name path. @@ -343,7 +330,6 @@ bool CMICmnLLDBDebugSessionInfo::AccessPath(const CMIUtilString &vPath, } //++ -//------------------------------------------------------------------------------------ // Details: Form MI partial response by appending more MI value type objects to // the // tuple type object past in. @@ -376,11 +362,9 @@ bool CMICmnLLDBDebugSessionInfo::MIResponseFormThreadInfo( // Add "target-id" const char *pThreadName = rThread.GetName(); - const MIuint len = - (pThreadName != nullptr) ? CMIUtilString(pThreadName).length() : 0; - const bool bHaveName = ((pThreadName != nullptr) && (len > 0) && (len < 32) && - CMIUtilString::IsAllValidAlphaAndNumeric( - pThreadName)); // 32 is arbitrary number + const MIuint len = CMIUtilString(pThreadName).length(); + const bool bHaveName = (len > 0) && (len < 32) && // 32 is arbitrary number + CMIUtilString::IsAllValidAlphaAndNumeric(pThreadName); const char *pThrdFmt = bHaveName ? "%s" : "Thread %d"; CMIUtilString strThread; if (bHaveName) @@ -411,7 +395,6 @@ bool CMICmnLLDBDebugSessionInfo::MIResponseFormThreadInfo( } //++ -//------------------------------------------------------------------------------------ // Details: Form MI partial response by appending more MI value type objects to // the // tuple type object past in. @@ -514,7 +497,6 @@ bool CMICmnLLDBDebugSessionInfo::MIResponseForVariableInfoInternal( } //++ -//------------------------------------------------------------------------------------ // Details: Extract the value's name and value or recurse into child value // object. // Type: Method. @@ -538,7 +520,6 @@ bool CMICmnLLDBDebugSessionInfo::GetVariableInfo(const lldb::SBValue &vrValue, } //++ -//------------------------------------------------------------------------------------ // Details: Form MI partial response by appending more MI value type objects to // the // tuple type object past in. @@ -609,7 +590,6 @@ bool CMICmnLLDBDebugSessionInfo::MIResponseFormFrameInfo( } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the frame information from LLDB frame object. // Type: Method. // Args: vrFrame - (R) LLDB thread object. @@ -651,7 +631,6 @@ bool CMICmnLLDBDebugSessionInfo::GetFrameInfo( } //++ -//------------------------------------------------------------------------------------ // Details: Form MI partial response by appending more MI value type objects to // the // tuple type object past in. @@ -686,7 +665,6 @@ void CMICmnLLDBDebugSessionInfo::MIResponseFormBrkPtFrameInfo( } //++ -//------------------------------------------------------------------------------------ // Details: Form MI partial response by appending more MI value type objects to // the // tuple type object past in. @@ -776,7 +754,6 @@ bool CMICmnLLDBDebugSessionInfo::MIResponseFormBrkPtInfo( } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve breakpoint information and write into the given breakpoint // information // object. Note not all possible information is retrieved and so the @@ -839,7 +816,6 @@ bool CMICmnLLDBDebugSessionInfo::GetBrkPtInfo(const lldb::SBBreakpoint &vBrkPt, } //++ -//------------------------------------------------------------------------------------ // Details: Get current debugger. // Type: Method. // Args: None. @@ -851,7 +827,6 @@ lldb::SBDebugger &CMICmnLLDBDebugSessionInfo::GetDebugger() const { } //++ -//------------------------------------------------------------------------------------ // Details: Get current listener. // Type: Method. // Args: None. @@ -863,7 +838,6 @@ lldb::SBListener &CMICmnLLDBDebugSessionInfo::GetListener() const { } //++ -//------------------------------------------------------------------------------------ // Details: Get current target. // Type: Method. // Args: None. @@ -878,7 +852,6 @@ lldb::SBTarget CMICmnLLDBDebugSessionInfo::GetTarget() const { } //++ -//------------------------------------------------------------------------------------ // Details: Get current process. // Type: Method. // Args: None. diff --git a/tools/lldb-mi/MICmnLLDBDebugSessionInfo.h b/tools/lldb-mi/MICmnLLDBDebugSessionInfo.h index 818df3b81b17..1fa81951f43a 100644 --- a/tools/lldb-mi/MICmnLLDBDebugSessionInfo.h +++ b/tools/lldb-mi/MICmnLLDBDebugSessionInfo.h @@ -1,9 +1,8 @@ //===-- MICmnLLDBDebugSessionInfo.h -----------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -243,7 +242,6 @@ private: }; //++ -//------------------------------------------------------------------------------------ // Details: Command instances can create and share data between other instances // of commands. // This function adds new data to the shared data. Using the same ID @@ -269,7 +267,6 @@ bool CMICmnLLDBDebugSessionInfo::SharedDataAdd(const CMIUtilString &vKey, } //++ -//------------------------------------------------------------------------------------ // Details: Command instances can create and share data between other instances // of commands. // This function retrieves data from the shared data container. diff --git a/tools/lldb-mi/MICmnLLDBDebugSessionInfoVarObj.cpp b/tools/lldb-mi/MICmnLLDBDebugSessionInfoVarObj.cpp index 234b4e631b49..fc0f76b6d495 100644 --- a/tools/lldb-mi/MICmnLLDBDebugSessionInfoVarObj.cpp +++ b/tools/lldb-mi/MICmnLLDBDebugSessionInfoVarObj.cpp @@ -1,9 +1,8 @@ //===-- MICmnLLDBDebugSessionInfoVarObj.cpp ---------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -29,7 +28,6 @@ CMICmnLLDBDebugSessionInfoVarObj::varFormat_e CMICmnLLDBDebugSessionInfoVarObj::ms_eDefaultFormat = eVarFormat_Natural; //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLLDBDebugSessionInfoVarObj constructor. // Type: Method. // Args: None. @@ -42,7 +40,6 @@ CMICmnLLDBDebugSessionInfoVarObj::CMICmnLLDBDebugSessionInfoVarObj() } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLLDBDebugSessionInfoVarObj constructor. // Type: Method. // Args: vrStrNameReal - (R) The actual name of the variable, the @@ -62,7 +59,6 @@ CMICmnLLDBDebugSessionInfoVarObj::CMICmnLLDBDebugSessionInfoVarObj( } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLLDBDebugSessionInfoVarObj constructor. // Type: Method. // Args: vrStrNameReal - (R) The actual name of the variable, the @@ -85,7 +81,6 @@ CMICmnLLDBDebugSessionInfoVarObj::CMICmnLLDBDebugSessionInfoVarObj( } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLLDBDebugSessionInfoVarObj copy constructor. // Type: Method. // Args: vrOther - (R) The object to copy from. @@ -98,7 +93,6 @@ CMICmnLLDBDebugSessionInfoVarObj::CMICmnLLDBDebugSessionInfoVarObj( } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLLDBDebugSessionInfoVarObj copy constructor. // Type: Method. // Args: vrOther - (R) The object to copy from. @@ -111,7 +105,6 @@ CMICmnLLDBDebugSessionInfoVarObj::CMICmnLLDBDebugSessionInfoVarObj( } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLLDBDebugSessionInfoVarObj move constructor. // Type: Method. // Args: vrwOther - (R) The object to copy from. @@ -124,7 +117,6 @@ CMICmnLLDBDebugSessionInfoVarObj::CMICmnLLDBDebugSessionInfoVarObj( } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLLDBDebugSessionInfoVarObj assignment operator. // Type: Method. // Args: vrOther - (R) The object to copy from. @@ -139,7 +131,6 @@ operator=(const CMICmnLLDBDebugSessionInfoVarObj &vrOther) { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLLDBDebugSessionInfoVarObj assignment operator. // Type: Method. // Args: vrwOther - (R) The object to copy from. @@ -154,7 +145,6 @@ operator=(CMICmnLLDBDebugSessionInfoVarObj &&vrwOther) { } //++ -//------------------------------------------------------------------------------------ // Details: Copy the other instance of that object to *this object. // Type: Method. // Args: vrOther - (R) The object to copy from. @@ -180,7 +170,6 @@ bool CMICmnLLDBDebugSessionInfoVarObj::CopyOther( } //++ -//------------------------------------------------------------------------------------ // Details: Move that object to *this object. // Type: Method. // Args: vrwOther - (RW) The object to copy from. @@ -207,7 +196,6 @@ bool CMICmnLLDBDebugSessionInfoVarObj::MoveOther( } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLLDBDebugSessionInfoVarObj destructor. // Type: Overridden. // Args: None. @@ -217,7 +205,6 @@ bool CMICmnLLDBDebugSessionInfoVarObj::MoveOther( CMICmnLLDBDebugSessionInfoVarObj::~CMICmnLLDBDebugSessionInfoVarObj() {} //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the var format enumeration for the specified string. // Type: Static method. // Args: vrStrFormat - (R) Text description of the var format. @@ -239,7 +226,6 @@ CMICmnLLDBDebugSessionInfoVarObj::GetVarFormatForString( } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the var format enumeration for the specified character. // Type: Static method. // Args: vcFormat - Character representing the var format. @@ -263,7 +249,6 @@ CMICmnLLDBDebugSessionInfoVarObj::GetVarFormatForChar(char vcFormat) { } //++ -//------------------------------------------------------------------------------------ // Details: Return the equivalent var value formatted string for the given value // type, // which was prepared for printing (i.e. value was escaped and now it's @@ -298,7 +283,6 @@ CMIUtilString CMICmnLLDBDebugSessionInfoVarObj::GetValueStringFormatted( } //++ -//------------------------------------------------------------------------------------ // Details: Return number formatted string according to the given value type. // Type: Static method. // Args: vnValue - (R) The number value to get formatted. @@ -341,7 +325,6 @@ CMIUtilString CMICmnLLDBDebugSessionInfoVarObj::GetStringFormatted( } //++ -//------------------------------------------------------------------------------------ // Details: Delete internal container contents. // Type: Static method. // Args: None. @@ -353,7 +336,6 @@ void CMICmnLLDBDebugSessionInfoVarObj::VarObjClear() { } //++ -//------------------------------------------------------------------------------------ // Details: Add a var object to the internal container. // Type: Static method. // Args: vrVarObj - (R) The var value object. @@ -368,7 +350,6 @@ void CMICmnLLDBDebugSessionInfoVarObj::VarObjAdd( } //++ -//------------------------------------------------------------------------------------ // Details: Delete the var object from the internal container matching the // specified name. // Type: Static method. @@ -386,7 +367,6 @@ void CMICmnLLDBDebugSessionInfoVarObj::VarObjDelete( } //++ -//------------------------------------------------------------------------------------ // Details: Update an existing var object in the internal container. // Type: Static method. // Args: vrVarObj - (R) The var value object. @@ -399,7 +379,6 @@ void CMICmnLLDBDebugSessionInfoVarObj::VarObjUpdate( } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the var object matching the specified name. // Type: Static method. // Args: vrVarName - (R) The var value name. @@ -422,7 +401,6 @@ bool CMICmnLLDBDebugSessionInfoVarObj::VarObjGet( } //++ -//------------------------------------------------------------------------------------ // Details: A count is kept of the number of var value objects created. This is // count is // used to ID the var value object. Reset the count to 0. @@ -436,7 +414,6 @@ void CMICmnLLDBDebugSessionInfoVarObj::VarObjIdResetToZero() { } //++ -//------------------------------------------------------------------------------------ // Details: Default format is globally used as the data format when "natural" is // in effect, that is, this overrides the default // Type: Static method. @@ -450,7 +427,6 @@ void CMICmnLLDBDebugSessionInfoVarObj::VarObjSetFormat( } //++ -//------------------------------------------------------------------------------------ // Details: A count is kept of the number of var value objects created. This is // count is // used to ID the var value object. Increment the count by 1. @@ -462,7 +438,6 @@ void CMICmnLLDBDebugSessionInfoVarObj::VarObjSetFormat( void CMICmnLLDBDebugSessionInfoVarObj::VarObjIdInc() { ms_nVarUniqueId++; } //++ -//------------------------------------------------------------------------------------ // Details: A count is kept of the number of var value objects created. This is // count is // used to ID the var value object. Retrieve ID. @@ -476,7 +451,6 @@ MIuint CMICmnLLDBDebugSessionInfoVarObj::VarObjIdGet() { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the value formatted object's name. // Type: Method. // Args: None. @@ -488,7 +462,6 @@ const CMIUtilString &CMICmnLLDBDebugSessionInfoVarObj::GetName() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the value formatted object's variable name as given in the // MI command // to create the var object. @@ -502,7 +475,6 @@ const CMIUtilString &CMICmnLLDBDebugSessionInfoVarObj::GetNameReal() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the value formatted string. // Type: Method. // Args: None. @@ -515,7 +487,6 @@ CMICmnLLDBDebugSessionInfoVarObj::GetValueFormatted() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the LLDB Value object. // Type: Method. // Args: None. @@ -527,7 +498,6 @@ lldb::SBValue &CMICmnLLDBDebugSessionInfoVarObj::GetValue() { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the LLDB Value object. // Type: Method. // Args: None. @@ -539,7 +509,6 @@ const lldb::SBValue &CMICmnLLDBDebugSessionInfoVarObj::GetValue() const { } //++ -//------------------------------------------------------------------------------------ // Details: Set the var format type for *this object and update the formatting. // Type: Method. // Args: None. @@ -558,7 +527,6 @@ bool CMICmnLLDBDebugSessionInfoVarObj::SetVarFormat( } //++ -//------------------------------------------------------------------------------------ // Details: Update *this var obj. Update it's value and type. // Type: Method. // Args: None. @@ -577,7 +545,6 @@ void CMICmnLLDBDebugSessionInfoVarObj::UpdateValue() { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the enumeration type of the var object. // Type: Method. // Args: None. @@ -590,7 +557,6 @@ CMICmnLLDBDebugSessionInfoVarObj::GetType() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the parent var object's name, the parent var object to // *this var // object (if assigned). The parent is equivalent to LLDB SBValue diff --git a/tools/lldb-mi/MICmnLLDBDebugSessionInfoVarObj.h b/tools/lldb-mi/MICmnLLDBDebugSessionInfoVarObj.h index 49854051b7fe..6cee598fccc3 100644 --- a/tools/lldb-mi/MICmnLLDBDebugSessionInfoVarObj.h +++ b/tools/lldb-mi/MICmnLLDBDebugSessionInfoVarObj.h @@ -1,9 +1,8 @@ //===-- MICmnLLDBDebugSessionInfoVarObj.h -----------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnLLDBDebugger.cpp b/tools/lldb-mi/MICmnLLDBDebugger.cpp index b102cab9f93a..b22e7d9a1fe6 100644 --- a/tools/lldb-mi/MICmnLLDBDebugger.cpp +++ b/tools/lldb-mi/MICmnLLDBDebugger.cpp @@ -1,9 +1,8 @@ //===-- MICmnLLDBDebugger.cpp -----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -30,7 +29,6 @@ #include "MIUtilSingletonHelper.h" //++ -//------------------------------------------------------------------------------------ // MI private summary providers static inline bool MI_char_summary_provider(lldb::SBValue value, lldb::SBTypeSummaryOptions options, @@ -44,10 +42,11 @@ static inline bool MI_char_summary_provider(lldb::SBValue value, lldb::BasicType type_code = value_type.GetBasicType(); if (type_code == lldb::eBasicTypeSignedChar) - stream.Printf("%d %s", (int)value.GetValueAsSigned(), value.GetValue()); + stream.Printf("%d %s", (int)value.GetValueAsSigned(), + CMIUtilString::WithNullAsEmpty(value.GetValue())); else if (type_code == lldb::eBasicTypeUnsignedChar) stream.Printf("%u %s", (unsigned)value.GetValueAsUnsigned(), - value.GetValue()); + CMIUtilString::WithNullAsEmpty(value.GetValue())); else return false; @@ -55,7 +54,6 @@ static inline bool MI_char_summary_provider(lldb::SBValue value, } //++ -//------------------------------------------------------------------------------------ // MI summary helper routines static inline bool MI_add_summary(lldb::SBTypeCategory category, const char *typeName, @@ -74,7 +72,6 @@ static inline bool MI_add_summary(lldb::SBTypeCategory category, } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLLDBDebugger constructor. // Type: Method. // Args: None. @@ -85,7 +82,6 @@ CMICmnLLDBDebugger::CMICmnLLDBDebugger() : m_constStrThisThreadId("MI debugger event") {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLLDBDebugger destructor. // Type: Overridable. // Args: None. @@ -95,7 +91,6 @@ CMICmnLLDBDebugger::CMICmnLLDBDebugger() CMICmnLLDBDebugger::~CMICmnLLDBDebugger() { Shutdown(); } //++ -//------------------------------------------------------------------------------------ // Details: Initialize resources for *this debugger object. // Type: Method. // Args: None. @@ -157,7 +152,6 @@ bool CMICmnLLDBDebugger::Initialize() { } //++ -//------------------------------------------------------------------------------------ // Details: Release resources for *this debugger object. // Type: Method. // Args: None. @@ -217,7 +211,6 @@ bool CMICmnLLDBDebugger::Shutdown() { } //++ -//------------------------------------------------------------------------------------ // Details: Return the LLDB debugger instance created for this debug session. // Type: Method. // Args: None. @@ -229,7 +222,6 @@ lldb::SBDebugger &CMICmnLLDBDebugger::GetTheDebugger() { } //++ -//------------------------------------------------------------------------------------ // Details: Return the LLDB listener instance created for this debug session. // Type: Method. // Args: None. @@ -241,7 +233,6 @@ lldb::SBListener &CMICmnLLDBDebugger::GetTheListener() { } //++ -//------------------------------------------------------------------------------------ // Details: Set the client driver that wants to use *this LLDB debugger. Call // this function // prior to Initialize(). @@ -258,7 +249,6 @@ bool CMICmnLLDBDebugger::SetDriver(const CMIDriverBase &vClientDriver) { } //++ -//------------------------------------------------------------------------------------ // Details: Get the client driver that is use *this LLDB debugger. // Type: Method. // Args: vClientDriver - (R) A driver. @@ -270,7 +260,6 @@ CMIDriverBase &CMICmnLLDBDebugger::GetDriver() const { } //++ -//------------------------------------------------------------------------------------ // Details: Wait until all events have been handled. // This function works in pair with // CMICmnLLDBDebugger::MonitorSBListenerEvents @@ -294,7 +283,6 @@ void CMICmnLLDBDebugger::WaitForHandleEvent() { } //++ -//------------------------------------------------------------------------------------ // Details: Check if need to rebroadcast stop event. This function will return // true if // debugger is in synchronouse mode. In such case the @@ -321,7 +309,6 @@ bool CMICmnLLDBDebugger::CheckIfNeedToRebroadcastStopEvent() { } //++ -//------------------------------------------------------------------------------------ // Details: Rebroadcast stop event if needed. This function should be called // only if the // CMICmnLLDBDebugger::CheckIfNeedToRebroadcastStopEvent() returned @@ -342,7 +329,6 @@ void CMICmnLLDBDebugger::RebroadcastStopEvent() { } //++ -//------------------------------------------------------------------------------------ // Details: Initialize the LLDB Debugger object. // Type: Method. // Args: None. @@ -363,7 +349,6 @@ bool CMICmnLLDBDebugger::InitSBDebugger() { } //++ -//------------------------------------------------------------------------------------ // Details: Set the LLDB Debugger's std in, err and out streams. (Not // implemented left // here for reference. Was called in the @@ -388,7 +373,6 @@ bool CMICmnLLDBDebugger::InitStdStreams() { } //++ -//------------------------------------------------------------------------------------ // Details: Set up the events from the SBDebugger's we would like to listen to. // Type: Method. // Args: None. @@ -443,7 +427,6 @@ bool CMICmnLLDBDebugger::InitSBListener() { } //++ -//------------------------------------------------------------------------------------ // Details: Register with the debugger, the SBListener, the type of events you // are interested // in. Others, like commands, may have already set the mask. @@ -481,7 +464,6 @@ bool CMICmnLLDBDebugger::RegisterForEvent( } //++ -//------------------------------------------------------------------------------------ // Details: Register with the debugger, the SBListener, the type of events you // are interested // in. Others, like commands, may have already set the mask. @@ -532,7 +514,6 @@ bool CMICmnLLDBDebugger::RegisterForEvent( } //++ -//------------------------------------------------------------------------------------ // Details: Unregister with the debugger, the SBListener, the type of events you // are no // longer interested in. Others, like commands, may still remain @@ -558,7 +539,7 @@ bool CMICmnLLDBDebugger::UnregisterForEvent( ClientGetMaskForAllClients(vBroadcasterClass); MIuint newEventMask = 0; for (MIuint i = 0; i < 32; i++) { - const MIuint bit = 1 << i; + const MIuint bit = MIuint(1) << i; const MIuint clientBit = bit & clientsEventMask; const MIuint othersBit = bit & otherClientsEventMask; if ((clientBit != 0) && (othersBit == 0)) { @@ -579,7 +560,6 @@ bool CMICmnLLDBDebugger::UnregisterForEvent( } //++ -//------------------------------------------------------------------------------------ // Details: Given the SBBroadcaster class name retrieve it's current event mask. // Type: Method. // Args: vBroadcasterClass - (R) The SBBroadcaster's class name. @@ -609,7 +589,6 @@ bool CMICmnLLDBDebugger::BroadcasterGetMask( } //++ -//------------------------------------------------------------------------------------ // Details: Remove the event mask for the specified SBBroadcaster class name. // Type: Method. // Args: vBroadcasterClass - (R) The SBBroadcaster's class name. @@ -629,7 +608,6 @@ bool CMICmnLLDBDebugger::BroadcasterRemoveMask( } //++ -//------------------------------------------------------------------------------------ // Details: Given the SBBroadcaster class name save it's current event mask. // Type: Method. // Args: vBroadcasterClass - (R) The SBBroadcaster's class name. @@ -655,7 +633,6 @@ bool CMICmnLLDBDebugger::BroadcasterSaveMask( } //++ -//------------------------------------------------------------------------------------ // Details: Iterate all the clients who have registered event masks against // particular // SBBroadcasters and build up the mask that is for all of them. @@ -683,7 +660,6 @@ MIuint CMICmnLLDBDebugger::ClientGetMaskForAllClients( } //++ -//------------------------------------------------------------------------------------ // Details: Given the client save its particular event requirements. // Type: Method. // Args: vClientName - (R) The Client's unique ID. @@ -714,7 +690,6 @@ bool CMICmnLLDBDebugger::ClientSaveMask(const CMIUtilString &vClientName, } //++ -//------------------------------------------------------------------------------------ // Details: Given the client remove it's particular event requirements. // Type: Method. // Args: vClientName - (R) The Client's unique ID. @@ -743,7 +718,6 @@ bool CMICmnLLDBDebugger::ClientRemoveTheirMask( } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the client's event mask used for on a particular // SBBroadcaster. // Type: Method. @@ -778,7 +752,6 @@ bool CMICmnLLDBDebugger::ClientGetTheirMask( } //++ -//------------------------------------------------------------------------------------ // Details: Momentarily wait for an events being broadcast and inspect those // that do // come this way. Check if the target should exit event if so start @@ -848,7 +821,6 @@ bool CMICmnLLDBDebugger::MonitorSBListenerEvents(bool &vrbIsAlive) { } //++ -//------------------------------------------------------------------------------------ // Details: The main worker method for this thread. // Type: Method. // Args: vrbIsAlive - (W) True = *this thread is working, false = thread has @@ -862,7 +834,6 @@ bool CMICmnLLDBDebugger::ThreadRun(bool &vrbIsAlive) { } //++ -//------------------------------------------------------------------------------------ // Details: Let this thread clean up after itself. // Type: Method. // Args: @@ -873,7 +844,6 @@ bool CMICmnLLDBDebugger::ThreadRun(bool &vrbIsAlive) { bool CMICmnLLDBDebugger::ThreadFinish() { return MIstatus::success; } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve *this thread object's name. // Type: Overridden. // Args: None. @@ -885,7 +855,6 @@ const CMIUtilString &CMICmnLLDBDebugger::ThreadGetName() const { } //++ -//------------------------------------------------------------------------------------ // Details: Loads lldb-mi formatters // Type: Method. // Args: None. @@ -913,7 +882,6 @@ bool CMICmnLLDBDebugger::LoadMIFormatters(lldb::SBTypeCategory miCategory) { } //++ -//------------------------------------------------------------------------------------ // Details: Registers lldb-mi custom summary providers // Type: Method. // Args: None. diff --git a/tools/lldb-mi/MICmnLLDBDebugger.h b/tools/lldb-mi/MICmnLLDBDebugger.h index bec9adf13830..29cf9416e153 100644 --- a/tools/lldb-mi/MICmnLLDBDebugger.h +++ b/tools/lldb-mi/MICmnLLDBDebugger.h @@ -1,9 +1,8 @@ //===-- MICmnLLDBDebugger.h -------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnLLDBDebuggerHandleEvents.cpp b/tools/lldb-mi/MICmnLLDBDebuggerHandleEvents.cpp index cd54c2bb5bc4..60cfd3563dae 100644 --- a/tools/lldb-mi/MICmnLLDBDebuggerHandleEvents.cpp +++ b/tools/lldb-mi/MICmnLLDBDebuggerHandleEvents.cpp @@ -1,9 +1,8 @@ //===-- MICmnLLDBDebuggerHandleEvents.cpp -----------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -44,7 +43,6 @@ #include <algorithm> //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLLDBDebuggerHandleEvents constructor. // Type: Method. // Args: None. @@ -54,7 +52,6 @@ CMICmnLLDBDebuggerHandleEvents::CMICmnLLDBDebuggerHandleEvents() {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLLDBDebuggerHandleEvents destructor. // Type: Overridable. // Args: None. @@ -66,7 +63,6 @@ CMICmnLLDBDebuggerHandleEvents::~CMICmnLLDBDebuggerHandleEvents() { } //++ -//------------------------------------------------------------------------------------ // Details: Initialize resources for *this broadcaster object. // Type: Method. // Args: None. @@ -91,7 +87,6 @@ bool CMICmnLLDBDebuggerHandleEvents::Initialize() { } //++ -//------------------------------------------------------------------------------------ // Details: Release resources for *this broadcaster object. // Type: Method. // Args: None. @@ -112,7 +107,6 @@ bool CMICmnLLDBDebuggerHandleEvents::Shutdown() { } //++ -//------------------------------------------------------------------------------------ // Details: Interpret the event object to ascertain the action to take or // information to // to form and put in a MI Out-of-band record object which is given to @@ -151,7 +145,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleEvent(const lldb::SBEvent &vEvent, } //++ -//------------------------------------------------------------------------------------ // Details: Handle a LLDB SBProcess event. // Type: Method. // Args: vEvent - (R) An LLDB broadcast event. @@ -202,7 +195,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleEventSBProcess( } //++ -//------------------------------------------------------------------------------------ // Details: Handle a LLDB SBBreakpoint event. // Type: Method. // Args: vEvent - (R) An LLDB broadcast event. @@ -275,7 +267,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleEventSBBreakPoint( } //++ -//------------------------------------------------------------------------------------ // Details: Handle a LLDB SBBreakpoint event. // Type: Method. // Args: vEvent - (R) An LLDB broadcast event. @@ -300,7 +291,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleEventSBBreakpointLocationsAdded( } //++ -//------------------------------------------------------------------------------------ // Details: Handle a LLDB SBBreakpoint event. // Type: Method. // Args: vEvent - (R) An LLDB broadcast event. @@ -369,7 +359,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleEventSBBreakpointCmn( } //++ -//------------------------------------------------------------------------------------ // Details: Handle a LLDB SBBreakpoint added event. // Add more breakpoint information or overwrite existing information. // Normally a break point session info objects exists by now when an MI @@ -494,7 +483,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleEventSBBreakpointAdded( } //++ -//------------------------------------------------------------------------------------ // Details: Handle a LLDB SBThread event. // Type: Method. // Args: vEvent - (R) An LLDB broadcast event. @@ -543,7 +531,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleEventSBThread( } //++ -//------------------------------------------------------------------------------------ // Details: Handle a LLDB SBThread event. // Type: Method. // Args: vEvent - (R) An LLDB broadcast event. @@ -577,7 +564,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleEventSBThreadSuspended( } //++ -//------------------------------------------------------------------------------------ // Details: Handle a LLDB SBThread event. // Type: Method. // Args: vEvent - (R) An LLDB broadcast event. @@ -597,7 +583,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleEventSBThreadBitStackChanged( } //++ -//------------------------------------------------------------------------------------ // Details: Handle a LLDB SBTarget event. // Type: Method. // Args: vEvent - (R) An LLDB broadcast event. @@ -646,7 +631,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleEventSBTarget( } //++ -//------------------------------------------------------------------------------------ // Details: Print to stdout // "=library-loaded,id=\"%s\",target-name=\"%s\",host-name=\"%s\",symbols-loaded="%d"[,symbols-path=\"%s\"],loaded_addr=\"0x%016" // PRIx64"\"" @@ -676,7 +660,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleTargetEventBroadcastBitModulesLoaded( } //++ -//------------------------------------------------------------------------------------ // Details: Print to stdout // "=library-unloaded,id=\"%s\",target-name=\"%s\",host-name=\"%s\",symbols-loaded="%d"[,symbols-path=\"%s\"],loaded_addr=\"0x%016" // PRIx64"\"" @@ -706,7 +689,6 @@ bool CMICmnLLDBDebuggerHandleEvents:: } //++ -//------------------------------------------------------------------------------------ // Details: Build module information for =library-loaded/=library-unloaded: // "id=\"%s\",target-name=\"%s\",host-name=\"%s\",symbols-loaded="%d"[,symbols-path=\"%s\"],loaded_addr=\"0x%016" // PRIx64"\"" @@ -784,7 +766,6 @@ bool CMICmnLLDBDebuggerHandleEvents::MiHelpGetModuleInfo( } //++ -//------------------------------------------------------------------------------------ // Details: Handle a LLDB SBCommandInterpreter event. // Type: Method. // Args: vEvent - (R) An LLDB command interpreter event. @@ -843,7 +824,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleEventSBCommandInterpreter( } //++ -//------------------------------------------------------------------------------------ // Details: Handle SBProcess event eBroadcastBitStateChanged. // Type: Method. // Args: vEvent - (R) An LLDB event object. @@ -939,7 +919,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleProcessEventBroadcastBitStateChanged( } //++ -//------------------------------------------------------------------------------------ // Details: Asynchronous event handler for LLDB Process state suspended. // Type: Method. // Args: vEvent - (R) An LLDB event object. @@ -972,7 +951,7 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleProcessEventStateSuspended( } else { const MIuint nTargetIndex = rDebugger.GetIndexOfTarget(target); if (nTargetIndex != UINT_MAX) - streamOut.Printf("Target %d: (", nTargetIndex); + streamOut.Printf("Target %" PRIu64 ": (", (uint64_t)nTargetIndex); else streamOut.Printf("Target <unknown index>: ("); target.GetDescription(streamOut, lldb::eDescriptionLevelBrief); @@ -984,7 +963,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleProcessEventStateSuspended( } //++ -//------------------------------------------------------------------------------------ // Details: Print to stdout MI formatted text to indicate process stopped. // Type: Method. // Args: vwrbShouldBrk - (W) True = Yes break, false = do not. @@ -1053,7 +1031,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleProcessEventStateStopped( } //++ -//------------------------------------------------------------------------------------ // Details: Asynchronous event handler for LLDB Process stop signal. // Type: Method. // Args: vrEvent - (R) An LLDB broadcast event. @@ -1204,7 +1181,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleProcessEventStopSignal( } //++ -//------------------------------------------------------------------------------------ // Details: Asynchronous event handler for LLDB Process stop exception. // Type: Method. // Args: None. @@ -1245,7 +1221,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleProcessEventStopException() { } //++ -//------------------------------------------------------------------------------------ // Details: Form partial MI response in a MI value tuple object. // Type: Method. // Args: vwrMiValueTuple - (W) MI value tuple object. @@ -1296,7 +1271,6 @@ bool CMICmnLLDBDebuggerHandleEvents::MiHelpGetCurrentThreadFrame( } //++ -//------------------------------------------------------------------------------------ // Details: Asynchronous event handler for LLDB Process stop reason breakpoint. // Type: Method. // Args: None. @@ -1326,7 +1300,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleProcessEventStopReasonBreakpoint() { } //++ -//------------------------------------------------------------------------------------ // Details: Form the MI Out-of-band response for stopped reason on hitting a // break point. // Type: Method. @@ -1426,7 +1399,6 @@ bool CMICmnLLDBDebuggerHandleEvents::MiStoppedAtBreakPoint( } //++ -//------------------------------------------------------------------------------------ // Details: Asynchronous event handler for LLDB Process stop reason trace. // Type: Method. // Args: None. @@ -1492,7 +1464,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleProcessEventStopReasonTrace() { } //++ -//------------------------------------------------------------------------------------ // Details: Asynchronous function update selected thread. // Type: Method. // Args: None. @@ -1565,7 +1536,6 @@ bool CMICmnLLDBDebuggerHandleEvents::UpdateSelectedThread() { } //++ -//------------------------------------------------------------------------------------ // Details: Print to stdout "*running,thread-id=\"all\"", "(gdb)". // Type: Method. // Args: None. @@ -1585,7 +1555,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleProcessEventStateRunning() { } //++ -//------------------------------------------------------------------------------------ // Details: Print to stdout "=thread-exited,id=\"%ld\",group-id=\"i1\"", // "=thread-group-exited,id=\"i1\",exit-code=\"0\""), // "*stopped,reason=\"exited-normally\"", @@ -1629,7 +1598,6 @@ bool CMICmnLLDBDebuggerHandleEvents::HandleProcessEventStateExited() { } //++ -//------------------------------------------------------------------------------------ // Details: Drain all stdout so we don't see any output come after we print our // prompts. // The process has stuff waiting for stdout; get it and write it out to @@ -1685,7 +1653,6 @@ bool CMICmnLLDBDebuggerHandleEvents::GetProcessStdout() { } //++ -//------------------------------------------------------------------------------------ // Details: Drain all stderr so we don't see any output come after we print our // prompts. // The process has stuff waiting for stderr; get it and write it out to @@ -1740,7 +1707,6 @@ bool CMICmnLLDBDebuggerHandleEvents::GetProcessStderr() { } //++ -//------------------------------------------------------------------------------------ // Details: Asynchronous event function check for state changes. // Type: Method. // Args: None. @@ -1836,7 +1802,6 @@ bool CMICmnLLDBDebuggerHandleEvents::ChkForStateChanges() { } //++ -//------------------------------------------------------------------------------------ // Details: Take a fully formed MI result record and send to the stdout stream. // Also output to the MI Log file. // Type: Method. @@ -1851,7 +1816,6 @@ bool CMICmnLLDBDebuggerHandleEvents::MiResultRecordToStdout( } //++ -//------------------------------------------------------------------------------------ // Details: Take a fully formed MI Out-of-band record and send to the stdout // stream. // Also output to the MI Log file. @@ -1867,7 +1831,6 @@ bool CMICmnLLDBDebuggerHandleEvents::MiOutOfBandRecordToStdout( } //++ -//------------------------------------------------------------------------------------ // Details: Take a text data and send to the stdout stream. Also output to the // MI Log // file. @@ -1882,7 +1845,6 @@ bool CMICmnLLDBDebuggerHandleEvents::TextToStdout(const CMIUtilString &vrTxt) { } //++ -//------------------------------------------------------------------------------------ // Details: Take a text data and send to the stderr stream. Also output to the // MI Log // file. @@ -1897,7 +1859,6 @@ bool CMICmnLLDBDebuggerHandleEvents::TextToStderr(const CMIUtilString &vrTxt) { } //++ -//------------------------------------------------------------------------------------ // Details: Initialize the member variables with the signal values in this // process // file. diff --git a/tools/lldb-mi/MICmnLLDBDebuggerHandleEvents.h b/tools/lldb-mi/MICmnLLDBDebuggerHandleEvents.h index 55764511a6a9..378d85e6f575 100644 --- a/tools/lldb-mi/MICmnLLDBDebuggerHandleEvents.h +++ b/tools/lldb-mi/MICmnLLDBDebuggerHandleEvents.h @@ -1,9 +1,8 @@ //===-- MICmnLLDBDebuggerHandleEvents.h -------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnLLDBProxySBValue.cpp b/tools/lldb-mi/MICmnLLDBProxySBValue.cpp index 5a3e8e43b5fe..14e39cd1f80a 100644 --- a/tools/lldb-mi/MICmnLLDBProxySBValue.cpp +++ b/tools/lldb-mi/MICmnLLDBProxySBValue.cpp @@ -1,9 +1,8 @@ //===-- MICmnLLDBProxySBValue.cpp -------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -18,7 +17,6 @@ #include "MIUtilString.h" //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the numerical value from the SBValue object. If the // function fails // it could indicate the SBValue object does not represent an internal @@ -52,7 +50,6 @@ bool CMICmnLLDBProxySBValue::GetValueAsUnsigned(const lldb::SBValue &vrValue, } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the numerical value from the SBValue object. If the // function fails // it could indicate the SBValue object does not represent an internal @@ -86,7 +83,6 @@ bool CMICmnLLDBProxySBValue::GetValueAsSigned(const lldb::SBValue &vrValue, } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the NUL terminated string from the SBValue object if it of // the type // unsigned char *. diff --git a/tools/lldb-mi/MICmnLLDBProxySBValue.h b/tools/lldb-mi/MICmnLLDBProxySBValue.h index 2559a60a1141..4852b60763ea 100644 --- a/tools/lldb-mi/MICmnLLDBProxySBValue.h +++ b/tools/lldb-mi/MICmnLLDBProxySBValue.h @@ -1,9 +1,8 @@ //===-- MICmnLLDBProxySBValue.h ---------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnLLDBUtilSBValue.cpp b/tools/lldb-mi/MICmnLLDBUtilSBValue.cpp index 5785bf2a6329..0e7df52b7b99 100644 --- a/tools/lldb-mi/MICmnLLDBUtilSBValue.cpp +++ b/tools/lldb-mi/MICmnLLDBUtilSBValue.cpp @@ -1,9 +1,8 @@ //===-- MICmnLLDBUtilSBValue.cpp --------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -22,7 +21,6 @@ static const char *kUnknownValue = "??"; static const char *kUnresolvedCompositeValue = "{...}"; //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLLDBUtilSBValue constructor. // Type: Method. // Args: vrValue - (R) The LLDB value object. @@ -42,7 +40,6 @@ CMICmnLLDBUtilSBValue::CMICmnLLDBUtilSBValue( } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLLDBUtilSBValue destructor. // Type: Method. // Args: None. @@ -52,7 +49,6 @@ CMICmnLLDBUtilSBValue::CMICmnLLDBUtilSBValue( CMICmnLLDBUtilSBValue::~CMICmnLLDBUtilSBValue() {} //++ -//------------------------------------------------------------------------------------ // Details: Retrieve from the LLDB SB Value object the name of the variable. If // the name // is invalid (or the SBValue object invalid) then "??" is returned. @@ -69,7 +65,6 @@ CMIUtilString CMICmnLLDBUtilSBValue::GetName() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve from the LLDB SB Value object the value of the variable // described in // text. If the value is invalid (or the SBValue object invalid) then @@ -120,7 +115,6 @@ CMIUtilString CMICmnLLDBUtilSBValue::GetValue( } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve from the LLDB SB Value object the value of the variable // described in // text if it has a simple format (not composite). @@ -247,7 +241,6 @@ CMICmnLLDBUtilSBValue::GetValueSummary(bool valueOnly, } //++ -//------------------------------------------------------------------------------------ // Details: Check that basic type is a char type. Char type can be signed or // unsigned. // Type: Static. @@ -269,7 +262,6 @@ bool CMICmnLLDBUtilSBValue::IsCharBasicType(lldb::BasicType eType) { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the flag stating whether this value object is a char type // or some // other type. Char type can be signed or unsigned. @@ -284,7 +276,6 @@ bool CMICmnLLDBUtilSBValue::IsCharType() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the flag stating whether first child value object of *this // object is // a char type or some other type. Returns false if there are not @@ -308,7 +299,6 @@ bool CMICmnLLDBUtilSBValue::IsFirstChildCharType() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the flag stating whether pointee object of *this object is // a char type or some other type. Returns false if there are not // children. Char @@ -331,7 +321,6 @@ bool CMICmnLLDBUtilSBValue::IsPointeeCharType() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the flag stating whether this value object is a integer // type or some // other type. Char type can be signed or unsigned and short or @@ -356,7 +345,6 @@ bool CMICmnLLDBUtilSBValue::IsIntegerType() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the flag stating whether this value object is a pointer // type or some // other type. @@ -370,7 +358,6 @@ bool CMICmnLLDBUtilSBValue::IsPointerType() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the flag stating whether this value object is an array type // or some // other type. @@ -384,7 +371,6 @@ bool CMICmnLLDBUtilSBValue::IsArrayType() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the C string data of value object by read the memory where // the // variable is held. @@ -419,7 +405,6 @@ CMICmnLLDBUtilSBValue::ReadCStringFromHostMemory(lldb::SBValue &vrValue, } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the state of the value object's name. // Type: Method. // Args: None. @@ -432,7 +417,6 @@ bool CMICmnLLDBUtilSBValue::IsNameUnknown() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the state of the value object's value data. // Type: Method. // Args: None. @@ -445,7 +429,6 @@ bool CMICmnLLDBUtilSBValue::IsValueUnknown() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the value object's type name if valid. // Type: Method. // Args: None. @@ -460,7 +443,6 @@ CMIUtilString CMICmnLLDBUtilSBValue::GetTypeName() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the value object's display type name if valid. // Type: Method. // Args: None. @@ -475,7 +457,6 @@ CMIUtilString CMICmnLLDBUtilSBValue::GetTypeNameDisplay() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve whether the value object's is valid or not. // Type: Method. // Args: None. @@ -485,7 +466,6 @@ CMIUtilString CMICmnLLDBUtilSBValue::GetTypeNameDisplay() const { bool CMICmnLLDBUtilSBValue::IsValid() const { return m_bValidSBValue; } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the value object' has a name. A value object can be valid // but still // have no name which suggest it is not a variable. @@ -506,7 +486,6 @@ bool CMICmnLLDBUtilSBValue::HasName() const { } //++ -//------------------------------------------------------------------------------------ // Details: Determine if the value object' represents a LLDB variable i.e. "$0". // Type: Method. // Args: None. diff --git a/tools/lldb-mi/MICmnLLDBUtilSBValue.h b/tools/lldb-mi/MICmnLLDBUtilSBValue.h index ef5849e6eafc..6804402b75d6 100644 --- a/tools/lldb-mi/MICmnLLDBUtilSBValue.h +++ b/tools/lldb-mi/MICmnLLDBUtilSBValue.h @@ -1,9 +1,8 @@ //===-- MICmnLLDBUtilSBValue.h ----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnLog.cpp b/tools/lldb-mi/MICmnLog.cpp index d30c03f5063d..fc4c3141915b 100644 --- a/tools/lldb-mi/MICmnLog.cpp +++ b/tools/lldb-mi/MICmnLog.cpp @@ -1,9 +1,8 @@ //===-- MICmnLog.cpp --------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -15,7 +14,6 @@ #include "MIUtilDateTimeStd.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLog constructor. // Type: Method. // Args: None. @@ -27,7 +25,6 @@ CMICmnLog::CMICmnLog() : m_bEnabled(false), m_bInitializingATM(false) { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLog destructor. // Type: Method. // Args: None. @@ -37,7 +34,6 @@ CMICmnLog::CMICmnLog() : m_bEnabled(false), m_bInitializingATM(false) { CMICmnLog::~CMICmnLog() { Shutdown(); } //++ -//------------------------------------------------------------------------------------ // Details: Initialize resources for *this Logger. // Type: Method. // Args: None. @@ -95,7 +91,6 @@ bool CMICmnLog::Initialize() { } //++ -//------------------------------------------------------------------------------------ // Details: Release resources for *this Logger. // Type: Method. // Args: None. @@ -120,7 +115,6 @@ bool CMICmnLog::Shutdown() { } //++ -//------------------------------------------------------------------------------------ // Details: Enabled or disable *this Logger from writing any data to registered // clients. // Type: Method. @@ -136,7 +130,6 @@ bool CMICmnLog::SetEnabled(const bool vbYes) { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve state whether *this Logger is enabled writing data to // registered clients. // Type: Method. @@ -148,7 +141,6 @@ bool CMICmnLog::SetEnabled(const bool vbYes) { bool CMICmnLog::GetEnabled() const { return m_bEnabled; } //++ -//------------------------------------------------------------------------------------ // Details: Unregister all the Mediums registered with *this Logger. // Type: Method. // Args: None. @@ -169,7 +161,6 @@ bool CMICmnLog::UnregisterMediumAll() { } //++ -//------------------------------------------------------------------------------------ // Details: Register a Medium with *this Logger. // Type: Method. // Args: vrMedium - (R) The medium to register. @@ -198,7 +189,6 @@ bool CMICmnLog::RegisterMedium(const IMedium &vrMedium) { } //++ -//------------------------------------------------------------------------------------ // Details: Query the Logger to see if a medium is already registered. // Type: Method. // Args: vrMedium - (R) The medium to query. @@ -213,7 +203,6 @@ bool CMICmnLog::HaveMediumAlready(const IMedium &vrMedium) const { } //++ -//------------------------------------------------------------------------------------ // Details: Unregister a medium from the Logger. // Type: Method. // Args: vrMedium - (R) The medium to unregister. @@ -229,7 +218,6 @@ bool CMICmnLog::UnregisterMedium(const IMedium &vrMedium) { } //++ -//------------------------------------------------------------------------------------ // Details: The callee client uses this function to write to the Logger. The // data to be // written is given out to all the mediums registered. The verbosity @@ -294,7 +282,6 @@ bool CMICmnLog::Write(const CMIUtilString &vData, const ELogVerbosity veType) { } //++ -//------------------------------------------------------------------------------------ // Details: Short cut function call to write only to the Log file. // The logger must be initialized successfully before a write to any // registered @@ -310,7 +297,6 @@ bool CMICmnLog::WriteLog(const CMIUtilString &vData) { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve a string detailing the last error. // Type: Method. // Args: None, @@ -322,7 +308,6 @@ const CMIUtilString &CMICmnLog::GetErrorDescription() const { } //++ -//------------------------------------------------------------------------------------ // Details: Set the internal description of the last error. // Type: Method. // Args: (R) String containing a description of the last error. @@ -334,7 +319,6 @@ void CMICmnLog::SetErrorDescription(const CMIUtilString &vrTxt) const { } //++ -//------------------------------------------------------------------------------------ // Details: Clear the last error. // Type: None. // Args: None. diff --git a/tools/lldb-mi/MICmnLog.h b/tools/lldb-mi/MICmnLog.h index 4b19c625a870..909dc613b02e 100644 --- a/tools/lldb-mi/MICmnLog.h +++ b/tools/lldb-mi/MICmnLog.h @@ -1,9 +1,8 @@ //===-- MICmnLog.h ----------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnLogMediumFile.cpp b/tools/lldb-mi/MICmnLogMediumFile.cpp index 9f94caf3be7f..7fbe28f3fe0f 100644 --- a/tools/lldb-mi/MICmnLogMediumFile.cpp +++ b/tools/lldb-mi/MICmnLogMediumFile.cpp @@ -1,9 +1,8 @@ //===-- MICmnLogMediumFile.cpp ----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -12,7 +11,6 @@ #include "MICmnResources.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLogMediumFile constructor. // Type: Method. // Args: None. @@ -30,7 +28,6 @@ CMICmnLogMediumFile::CMICmnLogMediumFile() m_fileHeaderTxt(MIRSRC(IDS_MEDIUMFILE_ERR_FILE_HEADER)) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmnLogMediumFile destructor. // Type: Overridden. // Args: None. @@ -40,7 +37,6 @@ CMICmnLogMediumFile::CMICmnLogMediumFile() CMICmnLogMediumFile::~CMICmnLogMediumFile() {} //++ -//------------------------------------------------------------------------------------ // Details: Get the singleton instance of *this class. // Type: Static. // Args: None. @@ -54,7 +50,6 @@ CMICmnLogMediumFile &CMICmnLogMediumFile::Instance() { } //++ -//------------------------------------------------------------------------------------ // Details: Initialize setup *this medium ready for use. // Type: Overridden. // Args: None. @@ -68,7 +63,6 @@ bool CMICmnLogMediumFile::Initialize() { } //++ -//------------------------------------------------------------------------------------ // Details: Unbind detach or release resources used by *this medium. // Type: Method. // Args: None. @@ -84,7 +78,6 @@ bool CMICmnLogMediumFile::Shutdown() { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the name of *this medium. // Type: Overridden. // Args: None. @@ -96,7 +89,6 @@ const CMIUtilString &CMICmnLogMediumFile::GetName() const { } //++ -//------------------------------------------------------------------------------------ // Details: The callee client calls the write function on the Logger. The data // to be // written is given out to all the mediums registered. The verbosity @@ -133,7 +125,6 @@ bool CMICmnLogMediumFile::Write(const CMIUtilString &vData, } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve *this medium's last error condition. // Type: Method. // Args: None. @@ -145,7 +136,6 @@ const CMIUtilString &CMICmnLogMediumFile::GetError() const { } //++ -//------------------------------------------------------------------------------------ // Details: Set the verbosity mode for this medium. // Type: Method. // Args: veType - (R) Mask value. @@ -159,7 +149,6 @@ bool CMICmnLogMediumFile::SetVerbosity(const MIuint veType) { } //++ -//------------------------------------------------------------------------------------ // Details: Get the verbosity mode for this medium. // Type: Method. // Args: veType - (R) Mask value. @@ -169,7 +158,6 @@ bool CMICmnLogMediumFile::SetVerbosity(const MIuint veType) { MIuint CMICmnLogMediumFile::GetVerbosity() const { return m_eVerbosityType; } //++ -//------------------------------------------------------------------------------------ // Details: Write data to a file English font. // Type: Method. // Args: vData - (R) The data to write to the logger. @@ -181,7 +169,6 @@ bool CMICmnLogMediumFile::FileWriteEnglish(const CMIUtilString &vData) { } //++ -//------------------------------------------------------------------------------------ // Details: Determine and form the medium file's directory path and name. // Type: Method. // Args: None. @@ -211,7 +198,6 @@ bool CMICmnLogMediumFile::FileFormFileNamePath() { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the medium file's directory path and name. // Type: Method. // Args: None. @@ -223,7 +209,6 @@ const CMIUtilString &CMICmnLogMediumFile::GetFileNamePath() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the medium file's name. // Type: Method. // Args: None. @@ -235,7 +220,6 @@ const CMIUtilString &CMICmnLogMediumFile::GetFileName() const { } //++ -//------------------------------------------------------------------------------------ // Details: Massage the data to behave correct when submitted to file. Insert // extra log // specific text. The veType is there to allow in the future to parse @@ -273,7 +257,6 @@ CMICmnLogMediumFile::MassagedData(const CMIUtilString &vData, } //++ -//------------------------------------------------------------------------------------ // Details: Convert the Log's verbosity type number into a single char // character. // Type: Method. @@ -300,7 +283,6 @@ char CMICmnLogMediumFile::ConvertLogVerbosityTypeToId( } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve state of whether the file medium is ok. // Type: Method. // Args: None. @@ -311,7 +293,6 @@ char CMICmnLogMediumFile::ConvertLogVerbosityTypeToId( bool CMICmnLogMediumFile::IsOk() const { return m_file.IsOk(); } //++ -//------------------------------------------------------------------------------------ // Details: Status on the file log medium existing already. // Type: Method. // Args: None. @@ -324,7 +305,6 @@ bool CMICmnLogMediumFile::IsFileExist() const { } //++ -//------------------------------------------------------------------------------------ // Details: Write the header text the logger file. // Type: Method. // Args: vText - (R) Text. @@ -337,7 +317,6 @@ bool CMICmnLogMediumFile::FileWriteHeader() { } //++ -//------------------------------------------------------------------------------------ // Details: Convert any carriage line returns to be compatible with the platform // the // Log file is being written to. @@ -366,7 +345,6 @@ CMIUtilString CMICmnLogMediumFile::ConvertCr(const CMIUtilString &vData) const { } //++ -//------------------------------------------------------------------------------------ // Details: Set the header text that is written to the logger file at the // beginning. // Type: Method. @@ -382,7 +360,6 @@ bool CMICmnLogMediumFile::SetHeaderTxt(const CMIUtilString &vText) { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the file current carriage line return characters used. // Type: Method. // Args: None. @@ -394,7 +371,6 @@ const CMIUtilString &CMICmnLogMediumFile::GetLineReturn() const { } //++ -//------------------------------------------------------------------------------------ // Details: Set the directory to place the log file. // Type: Method. // Args: vPath - (R) Path to log. diff --git a/tools/lldb-mi/MICmnLogMediumFile.h b/tools/lldb-mi/MICmnLogMediumFile.h index 0a734a1c77d5..85b0a9d4f581 100644 --- a/tools/lldb-mi/MICmnLogMediumFile.h +++ b/tools/lldb-mi/MICmnLogMediumFile.h @@ -1,9 +1,8 @@ //===-- MICmnLogMediumFile.h ------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnMIOutOfBandRecord.cpp b/tools/lldb-mi/MICmnMIOutOfBandRecord.cpp index 029f76e65a85..59856a6f165e 100644 --- a/tools/lldb-mi/MICmnMIOutOfBandRecord.cpp +++ b/tools/lldb-mi/MICmnMIOutOfBandRecord.cpp @@ -1,9 +1,8 @@ //===-- MICmnMIOutOfBandRecord.cpp ------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -54,7 +53,7 @@ MapOutOfBandToText(CMICmnMIOutOfBandRecord::OutOfBand_e veType) { return ""; } assert(false && "unknown CMICmnMIOutofBandRecord::OutOfBand_e"); - return NULL; + return nullptr; } static const char * @@ -96,11 +95,10 @@ MapOutOfBandToToken(CMICmnMIOutOfBandRecord::OutOfBand_e veType) { return "&"; } assert(false && "unknown CMICmnMIOutofBandRecord::OutOfBand_e"); - return NULL; + return nullptr; } //++ -//------------------------------------------------------------------------------------ // Details: Build the Out-of-band record's mandatory data part. The part up to // the first // (additional) result i.e. async-record ==> "*" type. @@ -110,12 +108,13 @@ MapOutOfBandToToken(CMICmnMIOutOfBandRecord::OutOfBand_e veType) { //-- static CMIUtilString BuildAsyncRecord(CMICmnMIOutOfBandRecord::OutOfBand_e veType) { - return CMIUtilString::Format("%s%s", MapOutOfBandToToken(veType), - MapOutOfBandToText(veType)); + auto Token = MapOutOfBandToToken(veType); + auto Text = MapOutOfBandToText(veType); + return CMIUtilString::Format("%s%s", CMIUtilString::WithNullAsEmpty(Token), + CMIUtilString::WithNullAsEmpty(Text)); } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIOutOfBandRecord constructor. // Type: Method. // Args: None. @@ -126,7 +125,6 @@ CMICmnMIOutOfBandRecord::CMICmnMIOutOfBandRecord() : m_strAsyncRecord(MIRSRC(IDS_CMD_ERR_EVENT_HANDLED_BUT_NO_ACTION)) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIOutOfBandRecord constructor. // Type: Method. // Args: veType - (R) A MI Out-of-Bound enumeration. @@ -137,7 +135,6 @@ CMICmnMIOutOfBandRecord::CMICmnMIOutOfBandRecord(OutOfBand_e veType) : m_strAsyncRecord(BuildAsyncRecord(veType)) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIOutOfBandRecord constructor. // Type: Method. // Args: veType - (R) A MI Out-of-Bound enumeration. @@ -152,7 +149,6 @@ CMICmnMIOutOfBandRecord::CMICmnMIOutOfBandRecord( } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIOutOfBandRecord constructor. // Type: Method. // Args: veType - (R) A MI Out-of-Bound enumeration. @@ -167,7 +163,6 @@ CMICmnMIOutOfBandRecord::CMICmnMIOutOfBandRecord( } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIOutOfBandRecord destructor. // Type: Overrideable. // Args: None. @@ -177,7 +172,6 @@ CMICmnMIOutOfBandRecord::CMICmnMIOutOfBandRecord( CMICmnMIOutOfBandRecord::~CMICmnMIOutOfBandRecord() {} //++ -//------------------------------------------------------------------------------------ // Details: Return the MI Out-of-band record as a string. The string is a direct // result of // work done on *this Out-of-band record so if not enough data is added @@ -196,7 +190,6 @@ const CMIUtilString &CMICmnMIOutOfBandRecord::GetString() const { } //++ -//------------------------------------------------------------------------------------ // Details: Add to *this Out-of-band record additional information. // Type: Method. // Args: vResult - (R) A MI result object. diff --git a/tools/lldb-mi/MICmnMIOutOfBandRecord.h b/tools/lldb-mi/MICmnMIOutOfBandRecord.h index 1bba38cf0cca..ab1faab8bc46 100644 --- a/tools/lldb-mi/MICmnMIOutOfBandRecord.h +++ b/tools/lldb-mi/MICmnMIOutOfBandRecord.h @@ -1,9 +1,8 @@ //===-- MICmnMIOutOfBandRecord.h --------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnMIResultRecord.cpp b/tools/lldb-mi/MICmnMIResultRecord.cpp index ea6fcf8fc59c..93bb5a60ec3d 100644 --- a/tools/lldb-mi/MICmnMIResultRecord.cpp +++ b/tools/lldb-mi/MICmnMIResultRecord.cpp @@ -1,9 +1,8 @@ //===-- MICmnMIResultRecord.cpp ---------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -15,7 +14,6 @@ #include "MICmnResources.h" //++ -//------------------------------------------------------------------------------------ // Details: Map a result class to the corresponding string. // Args: veType - (R) A MI result class enumeration. // Return: const char* - The string corresponding to the result class. @@ -36,11 +34,10 @@ MapResultClassToResultClassText(CMICmnMIResultRecord::ResultClass_e veType) { return "exit"; } assert(false && "unknown CMICmnMIResultRecord::ResultClass_e"); - return NULL; + return nullptr; } //++ -//------------------------------------------------------------------------------------ // Details: Build the result record's mandatory data part. The part up to the // first // (additional) result i.e. result-record ==> [ token ] "^" @@ -54,11 +51,11 @@ static const CMIUtilString BuildResultRecord(const CMIUtilString &vrToken, CMICmnMIResultRecord::ResultClass_e veType) { const char *pStrResultRecord = MapResultClassToResultClassText(veType); - return CMIUtilString::Format("%s^%s", vrToken.c_str(), pStrResultRecord); + return CMIUtilString::Format("%s^%s", vrToken.c_str(), + CMIUtilString::WithNullAsEmpty(pStrResultRecord)); } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIResultRecord constructor. // Type: Method. // Args: None. @@ -69,7 +66,6 @@ CMICmnMIResultRecord::CMICmnMIResultRecord() : m_strResultRecord(MIRSRC(IDS_CMD_ERR_CMD_RUN_BUT_NO_ACTION)) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIResultRecord constructor. // Type: Method. // Args: vrToken - (R) The command's transaction ID or token. @@ -82,7 +78,6 @@ CMICmnMIResultRecord::CMICmnMIResultRecord(const CMIUtilString &vrToken, : m_strResultRecord(BuildResultRecord(vrToken, veType)) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIResultRecord constructor. // Type: Method. // Args: vrToken - (R) The command's transaction ID or token. @@ -99,7 +94,6 @@ CMICmnMIResultRecord::CMICmnMIResultRecord(const CMIUtilString &vrToken, } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIResultRecord destructor. // Type: Overrideable. // Args: None. @@ -109,7 +103,6 @@ CMICmnMIResultRecord::CMICmnMIResultRecord(const CMIUtilString &vrToken, CMICmnMIResultRecord::~CMICmnMIResultRecord() {} //++ -//------------------------------------------------------------------------------------ // Details: Return the MI result record as a string. The string is a direct // result of // work done on *this result record so if not enough data is added then @@ -128,7 +121,6 @@ const CMIUtilString &CMICmnMIResultRecord::GetString() const { } //++ -//------------------------------------------------------------------------------------ // Details: Add to *this result record additional information. // Type: Method. // Args: vMIValue - (R) A MI value derived object. diff --git a/tools/lldb-mi/MICmnMIResultRecord.h b/tools/lldb-mi/MICmnMIResultRecord.h index 2018ad58e171..ae57007257c3 100644 --- a/tools/lldb-mi/MICmnMIResultRecord.h +++ b/tools/lldb-mi/MICmnMIResultRecord.h @@ -1,9 +1,8 @@ //===-- MICmnMIResultRecord.h -----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnMIValue.cpp b/tools/lldb-mi/MICmnMIValue.cpp index 6907b9e19adf..05ed71e584e0 100644 --- a/tools/lldb-mi/MICmnMIValue.cpp +++ b/tools/lldb-mi/MICmnMIValue.cpp @@ -1,9 +1,8 @@ //===-- MICmnMIValue.cpp ----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -12,7 +11,6 @@ #include "MICmnResources.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIValue constructor. // Type: Method. // Args: None. @@ -23,7 +21,6 @@ CMICmnMIValue::CMICmnMIValue() : m_strValue(MIRSRC(IDS_WORD_INVALIDBRKTS)), m_bJustConstructed(true) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIValue destructor. // Type: Overrideable. // Args: None. @@ -33,7 +30,6 @@ CMICmnMIValue::CMICmnMIValue() CMICmnMIValue::~CMICmnMIValue() {} //++ -//------------------------------------------------------------------------------------ // Details: Return the MI value as a string. The string is a direct result of // work done on *this value so if not enough data is added then it is // possible to return a malformed value. If nothing has been set or diff --git a/tools/lldb-mi/MICmnMIValue.h b/tools/lldb-mi/MICmnMIValue.h index 484a818e7f49..8f10c6793616 100644 --- a/tools/lldb-mi/MICmnMIValue.h +++ b/tools/lldb-mi/MICmnMIValue.h @@ -1,9 +1,8 @@ //===-- MICmnMIValue.h ------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnMIValueConst.cpp b/tools/lldb-mi/MICmnMIValueConst.cpp index 6fe16ab8cca9..1cdbc6487b29 100644 --- a/tools/lldb-mi/MICmnMIValueConst.cpp +++ b/tools/lldb-mi/MICmnMIValueConst.cpp @@ -1,9 +1,8 @@ //===-- MICmnMIValueConst.cpp -----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -14,7 +13,6 @@ const CMIUtilString CMICmnMIValueConst::ms_constStrDblQuote("\""); //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIValueConst constructor. // Type: Method. // Args: vString - (R) MI Const c-string value. @@ -27,7 +25,6 @@ CMICmnMIValueConst::CMICmnMIValueConst(const CMIUtilString &vString) } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIValueConst constructor. // Type: Method. // Args: vString - (R) MI Const c-string value. @@ -43,7 +40,6 @@ CMICmnMIValueConst::CMICmnMIValueConst(const CMIUtilString &vString, } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIValueConst destructor. // Type: Overrideable. // Args: None. @@ -53,7 +49,6 @@ CMICmnMIValueConst::CMICmnMIValueConst(const CMIUtilString &vString, CMICmnMIValueConst::~CMICmnMIValueConst() {} //++ -//------------------------------------------------------------------------------------ // Details: Build the Value Const data. // Type: Method. // Args: None. diff --git a/tools/lldb-mi/MICmnMIValueConst.h b/tools/lldb-mi/MICmnMIValueConst.h index 6b2862d5f257..4bac0864c9cf 100644 --- a/tools/lldb-mi/MICmnMIValueConst.h +++ b/tools/lldb-mi/MICmnMIValueConst.h @@ -1,9 +1,8 @@ //===-- MICmnMIValueConst.h -------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnMIValueList.cpp b/tools/lldb-mi/MICmnMIValueList.cpp index 28d21dbf3fb3..038d3ae36f02 100644 --- a/tools/lldb-mi/MICmnMIValueList.cpp +++ b/tools/lldb-mi/MICmnMIValueList.cpp @@ -1,9 +1,8 @@ //===-- MICmnMIValueList.cpp ------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -12,7 +11,6 @@ #include "MICmnResources.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIValueList constructor. // Type: Method. // Args: vbValueTypeList - (R) True = yes value type list, false = result @@ -25,7 +23,6 @@ CMICmnMIValueList::CMICmnMIValueList(const bool vbValueTypeList) { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIValueList constructor. // Construct a results only list. // return MIstatus::failure. @@ -41,7 +38,6 @@ CMICmnMIValueList::CMICmnMIValueList(const CMICmnMIValueResult &vResult) { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIValueList constructor. // Construct a value only list. // Type: Method. @@ -56,7 +52,6 @@ CMICmnMIValueList::CMICmnMIValueList(const CMICmnMIValue &vValue) { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIValueList destructor. // Type: Overrideable. // Args: None. @@ -66,7 +61,6 @@ CMICmnMIValueList::CMICmnMIValueList(const CMICmnMIValue &vValue) { CMICmnMIValueList::~CMICmnMIValueList() {} //++ -//------------------------------------------------------------------------------------ // Details: Build the result value's mandatory data part, one tuple // Type: Method. // Args: None. @@ -79,7 +73,6 @@ void CMICmnMIValueList::BuildList() { } //++ -//------------------------------------------------------------------------------------ // Details: Add another MI result object to the value list's of list is // results. // Only result objects can be added to a list of result otherwise this @@ -95,7 +88,6 @@ void CMICmnMIValueList::Add(const CMICmnMIValueResult &vResult) { } //++ -//------------------------------------------------------------------------------------ // Details: Add another MI value object to the value list's of list is values. // Only values objects can be added to a list of values otherwise this // function @@ -108,7 +100,6 @@ void CMICmnMIValueList::Add(const CMICmnMIValueResult &vResult) { void CMICmnMIValueList::Add(const CMICmnMIValue &vValue) { BuildList(vValue); } //++ -//------------------------------------------------------------------------------------ // Details: Add another MI result object to the value list's of list is // results. // Only result objects can be added to a list of result otherwise this @@ -135,7 +126,6 @@ void CMICmnMIValueList::BuildList(const CMICmnMIValueResult &vResult) { } //++ -//------------------------------------------------------------------------------------ // Details: Add another MI value object to the value list's of list is values. // Only values objects can be added to a list of values otherwise this // function @@ -165,7 +155,6 @@ void CMICmnMIValueList::BuildList(const CMICmnMIValue &vValue) { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the contents of *this value object but without the outer // most // brackets. diff --git a/tools/lldb-mi/MICmnMIValueList.h b/tools/lldb-mi/MICmnMIValueList.h index 8cf2c38aede6..76062d0b28d2 100644 --- a/tools/lldb-mi/MICmnMIValueList.h +++ b/tools/lldb-mi/MICmnMIValueList.h @@ -1,9 +1,8 @@ //===-- MICmnMIValueList.h --------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnMIValueResult.cpp b/tools/lldb-mi/MICmnMIValueResult.cpp index efbf0ddbbfb1..5ef60741342b 100644 --- a/tools/lldb-mi/MICmnMIValueResult.cpp +++ b/tools/lldb-mi/MICmnMIValueResult.cpp @@ -1,9 +1,8 @@ //===-- MICmnMIValueResult.cpp ----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -15,7 +14,6 @@ const CMIUtilString CMICmnMIValueResult::ms_constStrEqual("="); //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIValueResult constructor. // Type: Method. // Args: None. @@ -25,7 +23,6 @@ const CMIUtilString CMICmnMIValueResult::ms_constStrEqual("="); CMICmnMIValueResult::CMICmnMIValueResult() : m_bEmptyConstruction(true) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIValueResult constructor. // Type: Method. // Args: vrVariable - (R) MI value's name. @@ -41,7 +38,6 @@ CMICmnMIValueResult::CMICmnMIValueResult(const CMIUtilString &vrVariable, } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIValueResult constructor. // Type: Method. // Args: vrVariable - (R) MI value's name. @@ -60,7 +56,6 @@ CMICmnMIValueResult::CMICmnMIValueResult(const CMIUtilString &vrVariable, } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIValueResult destructor. // Type: Overrideable. // Args: None. @@ -70,7 +65,6 @@ CMICmnMIValueResult::CMICmnMIValueResult(const CMIUtilString &vrVariable, CMICmnMIValueResult::~CMICmnMIValueResult() {} //++ -//------------------------------------------------------------------------------------ // Details: Build the MI value result string. // Type: Method. // Args: None. @@ -85,7 +79,6 @@ void CMICmnMIValueResult::BuildResult() { } //++ -//------------------------------------------------------------------------------------ // Details: Build the MI value result string. // Type: Method. // Args: vrVariable - (R) MI value's name. @@ -102,7 +95,6 @@ void CMICmnMIValueResult::BuildResult(const CMIUtilString &vVariable, } //++ -//------------------------------------------------------------------------------------ // Details: Append another MI value object to *this MI value result. // Type: Method. // Args: vrVariable - (R) MI value's name. diff --git a/tools/lldb-mi/MICmnMIValueResult.h b/tools/lldb-mi/MICmnMIValueResult.h index 8a285a99d835..cfa101b86a5e 100644 --- a/tools/lldb-mi/MICmnMIValueResult.h +++ b/tools/lldb-mi/MICmnMIValueResult.h @@ -1,9 +1,8 @@ -//===-- MICmnMIResult.h -----------------------------------------*- C++ -*-===// +//===-- MICmnMIValueResult.h ------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnMIValueTuple.cpp b/tools/lldb-mi/MICmnMIValueTuple.cpp index 375ce50416cd..2f05d219d4fc 100644 --- a/tools/lldb-mi/MICmnMIValueTuple.cpp +++ b/tools/lldb-mi/MICmnMIValueTuple.cpp @@ -1,9 +1,8 @@ //===-- MICmnMIValueTuple.cpp -----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -11,7 +10,6 @@ #include "MICmnMIValueTuple.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIValueTuple constructor. // Type: Method. // Args: None. @@ -23,7 +21,6 @@ CMICmnMIValueTuple::CMICmnMIValueTuple() : m_bSpaceAfterComma(false) { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIValueTuple constructor. // Type: Method. // Args: vResult - (R) MI result object. @@ -38,7 +35,6 @@ CMICmnMIValueTuple::CMICmnMIValueTuple(const CMICmnMIValueResult &vResult) } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIValueTuple constructor. // Type: Method. // Args: vResult - (R) MI result object. @@ -56,7 +52,6 @@ CMICmnMIValueTuple::CMICmnMIValueTuple(const CMICmnMIValueResult &vResult, } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnMIValueTuple destructor. // Type: Overrideable. // Args: None. @@ -66,7 +61,6 @@ CMICmnMIValueTuple::CMICmnMIValueTuple(const CMICmnMIValueResult &vResult, CMICmnMIValueTuple::~CMICmnMIValueTuple() {} //++ -//------------------------------------------------------------------------------------ // Details: Build the result value's mandatory data part, one tuple // Type: Method. // Args: None. @@ -79,7 +73,6 @@ void CMICmnMIValueTuple::BuildTuple() { } //++ -//------------------------------------------------------------------------------------ // Details: Add another MI result object to the value's list of tuples. // Type: Method. // Args: vResult - (R) The MI result object. @@ -108,7 +101,6 @@ void CMICmnMIValueTuple::BuildTuple(const CMICmnMIValueResult &vResult) { } //++ -//------------------------------------------------------------------------------------ // Details: Add string value to the value's list of tuples. // Type: Method. // Args: vValue - (R) The string object. @@ -130,7 +122,6 @@ void CMICmnMIValueTuple::BuildTuple(const CMIUtilString &vValue) { } //++ -//------------------------------------------------------------------------------------ // Details: Add another MI value object to the value list's of list is values. // Only values objects can be added to a list of values otherwise this // function @@ -145,7 +136,6 @@ void CMICmnMIValueTuple::Add(const CMICmnMIValueResult &vResult) { } //++ -//------------------------------------------------------------------------------------ // Details: Add another MI value object to the value list's of list is values. // Only values objects can be added to a list of values otherwise this // function @@ -164,7 +154,6 @@ void CMICmnMIValueTuple::Add(const CMICmnMIValueResult &vResult, } //++ -//------------------------------------------------------------------------------------ // Details: Add another MI value object to the value list's of list is values. // Only values objects can be added to a list of values otherwise this // function @@ -183,7 +172,6 @@ void CMICmnMIValueTuple::Add(const CMICmnMIValueConst &vValue, } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the contents of *this value object but without the outer // most // brackets. diff --git a/tools/lldb-mi/MICmnMIValueTuple.h b/tools/lldb-mi/MICmnMIValueTuple.h index 095de23139ba..4a04fd9214e6 100644 --- a/tools/lldb-mi/MICmnMIValueTuple.h +++ b/tools/lldb-mi/MICmnMIValueTuple.h @@ -1,9 +1,8 @@ //===-- MICmnMIValueTuple.h -------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnResources.cpp b/tools/lldb-mi/MICmnResources.cpp index d8fa0a829245..3925f0b01dc5 100644 --- a/tools/lldb-mi/MICmnResources.cpp +++ b/tools/lldb-mi/MICmnResources.cpp @@ -1,9 +1,8 @@ //===-- MICmnResources.cpp --------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -462,7 +461,6 @@ const CMICmnResources::SRsrcTextData "Command '%s'. Must specify either a PID or a Name"}}; //++ -//------------------------------------------------------------------------------------ // Details: CMICmnResources constructor. // Type: Method. // Args: None. @@ -474,7 +472,6 @@ CMICmnResources::CMICmnResources() : m_nResourceId2TextDataSize(0) { } //++ -//------------------------------------------------------------------------------------ // Details: CMICmnResources destructor. // Type: Overridden. // Args: None. @@ -486,7 +483,6 @@ CMICmnResources::~CMICmnResources() { } //++ -//------------------------------------------------------------------------------------ // Details: Initialize the resources and set locality for the server. // Type: Method. // Args: None. @@ -506,7 +502,6 @@ bool CMICmnResources::Initialize() { } //++ -//------------------------------------------------------------------------------------ // Details: Release resources for *this object. // Type: Method. // Args: None. @@ -530,7 +525,6 @@ bool CMICmnResources::Shutdown() { } //++ -//------------------------------------------------------------------------------------ // Details: Initialize the resources and set locality for the server. // Type: Method. // Args: None. @@ -551,7 +545,6 @@ bool CMICmnResources::ReadResourceStringData() { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the corresponding text assigned to the resource ID. // Type: Method. // Args: vResourceId - (R) MI resource ID. @@ -568,7 +561,6 @@ CMIUtilString CMICmnResources::GetString(const MIuint vResourceId) const { } //++ -//------------------------------------------------------------------------------------ // Details: Determine the MI resource ID existings. // Type: Method. // Args: vResourceId - (R) MI resource ID. @@ -582,7 +574,6 @@ bool CMICmnResources::HasString(const MIuint vResourceId) const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the resource text data for the given resource ID. If a // resource ID // cannot be found and error is given returning the ID of the resource diff --git a/tools/lldb-mi/MICmnResources.h b/tools/lldb-mi/MICmnResources.h index 4177a95a5488..111b0c33899d 100644 --- a/tools/lldb-mi/MICmnResources.h +++ b/tools/lldb-mi/MICmnResources.h @@ -1,9 +1,8 @@ //===-- MICmnResources.h ----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnStreamStderr.cpp b/tools/lldb-mi/MICmnStreamStderr.cpp index 2bbbd4b50588..f4f6a3ab8fe9 100644 --- a/tools/lldb-mi/MICmnStreamStderr.cpp +++ b/tools/lldb-mi/MICmnStreamStderr.cpp @@ -1,10 +1,9 @@ //===-- MICmnStreamStderr.cpp ------------------------------------*- C++ //-*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -15,7 +14,6 @@ #include "MIDriver.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmnStreamStderr constructor. // Type: Method. // Args: None. @@ -25,7 +23,6 @@ CMICmnStreamStderr::CMICmnStreamStderr() {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmnStreamStderr destructor. // Type: Overridable. // Args: None. @@ -35,7 +32,6 @@ CMICmnStreamStderr::CMICmnStreamStderr() {} CMICmnStreamStderr::~CMICmnStreamStderr() { Shutdown(); } //++ -//------------------------------------------------------------------------------------ // Details: Initialize resources for *this stderr stream. // Type: Method. // Args: None. @@ -65,7 +61,6 @@ bool CMICmnStreamStderr::Initialize() { } //++ -//------------------------------------------------------------------------------------ // Details: Release resources for *this stderr stream. // Type: Method. // Args: None. @@ -88,7 +83,6 @@ bool CMICmnStreamStderr::Shutdown() { } //++ -//------------------------------------------------------------------------------------ // Details: Write text data to stderr. Prefix the message with "MI:". The text // data does // not need to include a carriage line return as this is added to the @@ -115,7 +109,6 @@ bool CMICmnStreamStderr::Write(const CMIUtilString &vText, } //++ -//------------------------------------------------------------------------------------ // Details: Write an LLDB text message to stderr. // The text data does not need to include a carriage line return as // this is added @@ -142,7 +135,6 @@ bool CMICmnStreamStderr::WriteLLDBMsg(const CMIUtilString &vText, } //++ -//------------------------------------------------------------------------------------ // Details: Write text data to stderr. The text data does not need to // include a carriage line return as this is added to the text. The // function also @@ -189,7 +181,6 @@ bool CMICmnStreamStderr::WritePriv(const CMIUtilString &vText, } //++ -//------------------------------------------------------------------------------------ // Details: Lock the availability of the stream stderr. Other users of *this // stream will // be stalled until it is available (Unlock()). @@ -205,7 +196,6 @@ bool CMICmnStreamStderr::Lock() { } //++ -//------------------------------------------------------------------------------------ // Details: Release a previously locked stderr. // Type: Method. // Args: None. @@ -219,7 +209,6 @@ bool CMICmnStreamStderr::Unlock() { } //++ -//------------------------------------------------------------------------------------ // Details: Take MI Driver text message and send to the stderr stream. Also // output to the // MI Log file. @@ -238,7 +227,6 @@ bool CMICmnStreamStderr::TextToStderr(const CMIUtilString &vrTxt) { } //++ -//------------------------------------------------------------------------------------ // Details: Take an LLDB message and send to the stderr stream. The message is // not always // an error message. The user has typed a command in to the Eclipse diff --git a/tools/lldb-mi/MICmnStreamStderr.h b/tools/lldb-mi/MICmnStreamStderr.h index 07943d02c4d0..65eea440dd7f 100644 --- a/tools/lldb-mi/MICmnStreamStderr.h +++ b/tools/lldb-mi/MICmnStreamStderr.h @@ -1,9 +1,8 @@ //===-- MICmnStreamStderr.h -------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnStreamStdin.cpp b/tools/lldb-mi/MICmnStreamStdin.cpp index 4d3fa2aabd96..4084b36a8916 100644 --- a/tools/lldb-mi/MICmnStreamStdin.cpp +++ b/tools/lldb-mi/MICmnStreamStdin.cpp @@ -1,9 +1,8 @@ //===-- MICmnStreamStdin.cpp ------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -22,7 +21,6 @@ #include "MIUtilSingletonHelper.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmnStreamStdin constructor. // Type: Method. // Args: None. @@ -33,7 +31,6 @@ CMICmnStreamStdin::CMICmnStreamStdin() : m_strPromptCurrent("(gdb)"), m_bShowPrompt(true), m_pCmdBuffer(nullptr) {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmnStreamStdin destructor. // Type: Overridable. // Args: None. @@ -43,7 +40,6 @@ CMICmnStreamStdin::CMICmnStreamStdin() CMICmnStreamStdin::~CMICmnStreamStdin() { Shutdown(); } //++ -//------------------------------------------------------------------------------------ // Details: Initialize resources for *this Stdin stream. // Type: Method. // Args: None. @@ -80,7 +76,6 @@ bool CMICmnStreamStdin::Initialize() { } //++ -//------------------------------------------------------------------------------------ // Details: Release resources for *this Stdin stream. // Type: Method. // Args: None. @@ -118,7 +113,6 @@ bool CMICmnStreamStdin::Shutdown() { } //++ -//------------------------------------------------------------------------------------ // Details: Validate and set the text that forms the prompt on the command line. // Type: Method. // Args: vNewPrompt - (R) Text description. @@ -140,7 +134,6 @@ bool CMICmnStreamStdin::SetPrompt(const CMIUtilString &vNewPrompt) { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the command line prompt text currently being used. // Type: Method. // Args: None. @@ -152,7 +145,6 @@ const CMIUtilString &CMICmnStreamStdin::GetPrompt() const { } //++ -//------------------------------------------------------------------------------------ // Details: Set whether to display optional command line prompt. The prompt is // output to // stdout. Disable it when this may interfere with the client reading @@ -170,7 +162,6 @@ void CMICmnStreamStdin::SetEnablePrompt(const bool vbYes) { } //++ -//------------------------------------------------------------------------------------ // Details: Get whether to display optional command line prompt. The prompt is // output to // stdout. Disable it when this may interfere with the client reading @@ -185,7 +176,6 @@ void CMICmnStreamStdin::SetEnablePrompt(const bool vbYes) { bool CMICmnStreamStdin::GetEnablePrompt() const { return m_bShowPrompt; } //++ -//------------------------------------------------------------------------------------ // Details: Wait on new line of data from stdin stream (completed by '\n' or // '\r'). // Type: Method. diff --git a/tools/lldb-mi/MICmnStreamStdin.h b/tools/lldb-mi/MICmnStreamStdin.h index 6483e90c6cbf..b193757eb747 100644 --- a/tools/lldb-mi/MICmnStreamStdin.h +++ b/tools/lldb-mi/MICmnStreamStdin.h @@ -1,9 +1,8 @@ //===-- MICmnStreamStdin.h --------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnStreamStdout.cpp b/tools/lldb-mi/MICmnStreamStdout.cpp index 064c74fab20c..4a0e2d16adc1 100644 --- a/tools/lldb-mi/MICmnStreamStdout.cpp +++ b/tools/lldb-mi/MICmnStreamStdout.cpp @@ -1,9 +1,8 @@ //===-- MICmnStreamStdout.cpp -----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -14,7 +13,6 @@ #include "MIDriver.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmnStreamStdout constructor. // Type: Method. // Args: None. @@ -24,7 +22,6 @@ CMICmnStreamStdout::CMICmnStreamStdout() {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmnStreamStdout destructor. // Type: Overridable. // Args: None. @@ -34,7 +31,6 @@ CMICmnStreamStdout::CMICmnStreamStdout() {} CMICmnStreamStdout::~CMICmnStreamStdout() { Shutdown(); } //++ -//------------------------------------------------------------------------------------ // Details: Initialize resources for *this Stdout stream. // Type: Method. // Args: None. @@ -64,7 +60,6 @@ bool CMICmnStreamStdout::Initialize() { } //++ -//------------------------------------------------------------------------------------ // Details: Release resources for *this Stdout stream. // Type: Method. // Args: None. @@ -87,7 +82,6 @@ bool CMICmnStreamStdout::Shutdown() { } //++ -//------------------------------------------------------------------------------------ // Details: Write an MI format type response to stdout. The text data does not // need to // include a carriage line return as this is added to the text. The @@ -107,7 +101,6 @@ bool CMICmnStreamStdout::WriteMIResponse(const CMIUtilString &vText, } //++ -//------------------------------------------------------------------------------------ // Details: Write text data to stdout. The text data does not need to // include a carriage line return as this is added to the text. The // function also @@ -133,7 +126,6 @@ bool CMICmnStreamStdout::Write(const CMIUtilString &vText, } //++ -//------------------------------------------------------------------------------------ // Details: Write text data to stdout. The text data does not need to // include a carriage line return as this is added to the text. The // function also @@ -180,7 +172,6 @@ bool CMICmnStreamStdout::WritePriv(const CMIUtilString &vText, } //++ -//------------------------------------------------------------------------------------ // Details: Lock the availability of the stream stdout. Other users of *this // stream will // be stalled until it is available (Unlock()). @@ -196,7 +187,6 @@ bool CMICmnStreamStdout::Lock() { } //++ -//------------------------------------------------------------------------------------ // Details: Release a previously locked stdout. // Type: Method. // Args: None. @@ -210,7 +200,6 @@ bool CMICmnStreamStdout::Unlock() { } //++ -//------------------------------------------------------------------------------------ // Details: Take a text data and send to the stdout stream. Also output to the // MI Log // file. @@ -226,7 +215,6 @@ bool CMICmnStreamStdout::TextToStdout(const CMIUtilString &vrTxt) { } //++ -//------------------------------------------------------------------------------------ // Details: Write prompt to stdout if it's enabled. // Type: Static method. // Args: None. diff --git a/tools/lldb-mi/MICmnStreamStdout.h b/tools/lldb-mi/MICmnStreamStdout.h index 928dcc2c1c4e..f73b56ca2ee4 100644 --- a/tools/lldb-mi/MICmnStreamStdout.h +++ b/tools/lldb-mi/MICmnStreamStdout.h @@ -1,9 +1,8 @@ //===-- MICmnStreamStdout.h -------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MICmnThreadMgrStd.cpp b/tools/lldb-mi/MICmnThreadMgrStd.cpp index efa24d60250a..25afbbcb5d1c 100644 --- a/tools/lldb-mi/MICmnThreadMgrStd.cpp +++ b/tools/lldb-mi/MICmnThreadMgrStd.cpp @@ -1,9 +1,8 @@ //===-- MICmnThreadMgrStd.cpp -----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -14,7 +13,6 @@ #include "MIUtilSingletonHelper.h" //++ -//------------------------------------------------------------------------------------ // Details: CMICmnThreadMgr constructor. // Type: Method. // Args: None. @@ -24,7 +22,6 @@ CMICmnThreadMgrStd::CMICmnThreadMgrStd() {} //++ -//------------------------------------------------------------------------------------ // Details: CMICmnThreadMgr destructor. // Type: Method. // Args: None. @@ -34,7 +31,6 @@ CMICmnThreadMgrStd::CMICmnThreadMgrStd() {} CMICmnThreadMgrStd::~CMICmnThreadMgrStd() { Shutdown(); } //++ -//------------------------------------------------------------------------------------ // Details: Initialise resources for *this thread manager. // Type: Method. // Args: None. @@ -71,7 +67,6 @@ bool CMICmnThreadMgrStd::Initialize() { } //++ -//------------------------------------------------------------------------------------ // Details: Release resources for *this thread manager. // Type: Method. // Args: None. @@ -108,7 +103,6 @@ bool CMICmnThreadMgrStd::Shutdown() { } //++ -//------------------------------------------------------------------------------------ // Details: Ask the thread manager to kill all threads and wait until they have // died // Type: Method. @@ -135,7 +129,6 @@ bool CMICmnThreadMgrStd::ThreadAllTerminate() { } //++ -//------------------------------------------------------------------------------------ // Details: Add a thread object to *this manager's list of thread objects. The // list to // used to manage thread objects centrally. diff --git a/tools/lldb-mi/MICmnThreadMgrStd.h b/tools/lldb-mi/MICmnThreadMgrStd.h index 86f5bc7373c9..ce8dd70525f3 100644 --- a/tools/lldb-mi/MICmnThreadMgrStd.h +++ b/tools/lldb-mi/MICmnThreadMgrStd.h @@ -1,9 +1,8 @@ //===-- MICmnThreadMgrStd.h -------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -65,7 +64,6 @@ private: }; //++ -//------------------------------------------------------------------------------------ // Details: Given a thread object start its (worker) thread to do work. The // object is // added to the *this manager for housekeeping and deletion of all diff --git a/tools/lldb-mi/MIDataTypes.h b/tools/lldb-mi/MIDataTypes.h index 59ff099389cb..c1ed764e46c6 100644 --- a/tools/lldb-mi/MIDataTypes.h +++ b/tools/lldb-mi/MIDataTypes.h @@ -1,9 +1,8 @@ //===-- MIDataTypes.h -------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -15,7 +14,6 @@ #pragma once -//-------------------------------------------------------------------------------------- // Windows headers: #ifdef _WIN32 @@ -26,7 +24,6 @@ #endif // _WIN32 -//-------------------------------------------------------------------------------------- // Common definitions: // Function return status @@ -56,7 +53,6 @@ typedef unsigned int MIuint; #endif // _WIN32 #endif // _WIN64 -//-------------------------------------------------------------------------------------- // Common types: // Fundamentals: diff --git a/tools/lldb-mi/MIDriver.cpp b/tools/lldb-mi/MIDriver.cpp index cb8fb1c2c25f..3bf888e303d4 100644 --- a/tools/lldb-mi/MIDriver.cpp +++ b/tools/lldb-mi/MIDriver.cpp @@ -1,9 +1,8 @@ //===-- MIDriver.cpp --------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -44,7 +43,6 @@ const CMIUtilString const CMIUtilString CMIDriver::ms_constAppNameLong(MIRSRC(IDS_MI_APPNAME_LONG)); //++ -//------------------------------------------------------------------------------------ // Details: CMIDriver constructor. // Type: Method. // Args: None. @@ -53,7 +51,7 @@ const CMIUtilString CMIDriver::ms_constAppNameLong(MIRSRC(IDS_MI_APPNAME_LONG)); //-- CMIDriver::CMIDriver() : m_bFallThruToOtherDriverEnabled(false), m_bDriverIsExiting(false), - m_handleMainThread(0), m_rStdin(CMICmnStreamStdin::Instance()), + m_handleMainThread(nullptr), m_rStdin(CMICmnStreamStdin::Instance()), m_rLldbDebugger(CMICmnLLDBDebugger::Instance()), m_rStdOut(CMICmnStreamStdout::Instance()), m_eCurrentDriverState(eDriverState_NotRunning), @@ -62,7 +60,6 @@ CMIDriver::CMIDriver() m_bHaveCommandFileNamePathOnCmdLine(false) {} //++ -//------------------------------------------------------------------------------------ // Details: CMIDriver destructor. // Type: Overridden. // Args: None. @@ -72,7 +69,6 @@ CMIDriver::CMIDriver() CMIDriver::~CMIDriver() {} //++ -//------------------------------------------------------------------------------------ // Details: Set whether *this driver (the parent) is enabled to pass a command // to its // fall through (child) driver to interpret the command and do work @@ -91,7 +87,6 @@ bool CMIDriver::SetEnableFallThru(const bool vbYes) { } //++ -//------------------------------------------------------------------------------------ // Details: Get whether *this driver (the parent) is enabled to pass a command // to its // fall through (child) driver to interpret the command and do work @@ -107,7 +102,6 @@ bool CMIDriver::GetEnableFallThru() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve MI's application name of itself. // Type: Method. // Args: None. @@ -119,7 +113,6 @@ const CMIUtilString &CMIDriver::GetAppNameShort() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve MI's application name of itself. // Type: Method. // Args: None. @@ -131,7 +124,6 @@ const CMIUtilString &CMIDriver::GetAppNameLong() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve MI's version description of itself. // Type: Method. // Args: None. @@ -143,7 +135,6 @@ const CMIUtilString &CMIDriver::GetVersionDescription() const { } //++ -//------------------------------------------------------------------------------------ // Details: Initialize setup *this driver ready for use. // Type: Method. // Args: None. @@ -192,7 +183,6 @@ bool CMIDriver::Initialize() { } //++ -//------------------------------------------------------------------------------------ // Details: Unbind detach or release resources used by *this driver. // Type: Method. // Args: None. @@ -239,7 +229,6 @@ bool CMIDriver::Shutdown() { } //++ -//------------------------------------------------------------------------------------ // Details: Work function. Client (the driver's user) is able to append their // own message // in to the MI's Log trace file. @@ -256,7 +245,6 @@ bool CMIDriver::WriteMessageToLog(const CMIUtilString &vMessage) { } //++ -//------------------------------------------------------------------------------------ // Details: CDriverMgr calls *this driver initialize setup ready for use. // Type: Overridden. // Args: None. @@ -267,7 +255,6 @@ bool CMIDriver::WriteMessageToLog(const CMIUtilString &vMessage) { bool CMIDriver::DoInitialize() { return CMIDriver::Instance().Initialize(); } //++ -//------------------------------------------------------------------------------------ // Details: CDriverMgr calls *this driver to unbind detach or release resources // used by // *this driver. @@ -280,7 +267,6 @@ bool CMIDriver::DoInitialize() { return CMIDriver::Instance().Initialize(); } bool CMIDriver::DoShutdown() { return CMIDriver::Instance().Shutdown(); } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the name for *this driver. // Type: Overridden. // Args: None. @@ -297,7 +283,6 @@ const CMIUtilString &CMIDriver::GetName() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve *this driver's last error condition. // Type: Overridden. // Args: None. @@ -307,7 +292,6 @@ const CMIUtilString &CMIDriver::GetName() const { CMIUtilString CMIDriver::GetError() const { return GetErrorDescription(); } //++ -//------------------------------------------------------------------------------------ // Details: Call *this driver to return it's debugger. // Type: Overridden. // Args: None. @@ -319,7 +303,6 @@ lldb::SBDebugger &CMIDriver::GetTheDebugger() { } //++ -//------------------------------------------------------------------------------------ // Details: Specify another driver *this driver can call should this driver not // be able // to handle the client data input. DoFallThruToAnotherDriver() makes @@ -337,7 +320,6 @@ bool CMIDriver::SetDriverToFallThruTo(const CMIDriverBase &vrOtherDriver) { } //++ -//------------------------------------------------------------------------------------ // Details: Proxy function CMIDriverMgr IDriver interface implementation. *this // driver's // implementation called from here to match the existing function name @@ -374,7 +356,6 @@ lldb::SBError CMIDriver::DoParseArgs(const int argc, const char *argv[], } //++ -//------------------------------------------------------------------------------------ // Details: Check the arguments that were passed to this program to make sure // they are // valid and to get their argument values (if any). The following are @@ -484,7 +465,6 @@ lldb::SBError CMIDriver::ParseArgs(const int argc, const char *argv[], } //++ -//------------------------------------------------------------------------------------ // Details: A client can ask if *this driver is GDB/MI compatible. // Type: Overridden. // Args: None. @@ -495,7 +475,6 @@ lldb::SBError CMIDriver::ParseArgs(const int argc, const char *argv[], bool CMIDriver::GetDriverIsGDBMICompatibleDriver() const { return true; } //++ -//------------------------------------------------------------------------------------ // Details: Start worker threads for the driver. // Type: Method. // Args: None. @@ -522,7 +501,6 @@ bool CMIDriver::StartWorkerThreads() { } //++ -//------------------------------------------------------------------------------------ // Details: Stop worker threads for the driver. // Type: Method. // Args: None. @@ -536,7 +514,6 @@ bool CMIDriver::StopWorkerThreads() { } //++ -//------------------------------------------------------------------------------------ // Details: Call this function puts *this driver to work. // This function is used by the application's main thread. // Type: Overridden. @@ -611,7 +588,6 @@ bool CMIDriver::DoMainLoop() { } //++ -//------------------------------------------------------------------------------------ // Details: Set things in motion, set state etc that brings *this driver (and // the // application) to a tidy shutdown. @@ -635,7 +611,6 @@ bool CMIDriver::DoAppQuit() { } //++ -//------------------------------------------------------------------------------------ // Details: *this driver passes text commands to a fall through driver is it // does not // understand them (the LLDB driver). @@ -687,7 +662,6 @@ bool CMIDriver::InterpretCommandFallThruDriver(const CMIUtilString &vTextLine, } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the name for *this driver. // Type: Overridden. // Args: None. @@ -697,7 +671,6 @@ bool CMIDriver::InterpretCommandFallThruDriver(const CMIUtilString &vTextLine, const CMIUtilString &CMIDriver::GetDriverName() const { return GetName(); } //++ -//------------------------------------------------------------------------------------ // Details: Get the unique ID for *this driver. // Type: Overridden. // Args: None. @@ -707,7 +680,6 @@ const CMIUtilString &CMIDriver::GetDriverName() const { return GetName(); } const CMIUtilString &CMIDriver::GetDriverId() const { return GetId(); } //++ -//------------------------------------------------------------------------------------ // Details: This function allows *this driver to call on another driver to // perform work // should this driver not be able to handle the client data input. @@ -732,7 +704,6 @@ bool CMIDriver::DoFallThruToAnotherDriver(const CMIUtilString &vCmd, } //++ -//------------------------------------------------------------------------------------ // Details: *this driver provides a file stream to other drivers on which *this // driver // write's out to and they read as expected input. *this driver is @@ -753,7 +724,6 @@ FILE *CMIDriver::GetStdin() const { } //++ -//------------------------------------------------------------------------------------ // Details: *this driver provides a file stream to other pass through assigned // drivers // so they know what to write to. @@ -767,11 +737,10 @@ FILE *CMIDriver::GetStdout() const { // available before *this driver has been initialized! Flaw? // Do not want to pass through driver to write to stdout - return NULL; + return nullptr; } //++ -//------------------------------------------------------------------------------------ // Details: *this driver provides a error file stream to other pass through // assigned drivers // so they know what to write to. @@ -790,7 +759,6 @@ FILE *CMIDriver::GetStderr() const { } //++ -//------------------------------------------------------------------------------------ // Details: Set a unique ID for *this driver. It cannot be empty. // Type: Overridden. // Args: vId - (R) Text description. @@ -810,7 +778,6 @@ bool CMIDriver::SetId(const CMIUtilString &vId) { } //++ -//------------------------------------------------------------------------------------ // Details: Get the unique ID for *this driver. // Type: Overridden. // Args: None. @@ -820,7 +787,6 @@ bool CMIDriver::SetId(const CMIUtilString &vId) { const CMIUtilString &CMIDriver::GetId() const { return m_strDriverId; } //++ -//------------------------------------------------------------------------------------ // Details: Interpret the text data and match against current commands to see if // there // is a match. If a match then the command is issued and actioned on. @@ -850,7 +816,6 @@ bool CMIDriver::InterpretCommand(const CMIUtilString &vTextLine) { } //++ -//------------------------------------------------------------------------------------ // Details: Helper function for CMIDriver::InterpretCommandThisDriver. // Convert a CLI command to MI command (just wrap any CLI command // into "<tokens>-interpreter-exec command \"<CLI command>\""). @@ -926,7 +891,6 @@ CMIDriver::WrapCLICommandIntoMICommand(const CMIUtilString &vTextLine) const { } //++ -//------------------------------------------------------------------------------------ // Details: Interpret the text data and match against current commands to see if // there // is a match. If a match then the command is issued and actioned on. @@ -999,7 +963,6 @@ bool CMIDriver::InterpretCommandThisDriver(const CMIUtilString &vTextLine, } //++ -//------------------------------------------------------------------------------------ // Details: Having previously had the potential command validated and found // valid now // get the command executed. @@ -1016,7 +979,6 @@ bool CMIDriver::ExecuteCommand(const SMICmdData &vCmdData) { } //++ -//------------------------------------------------------------------------------------ // Details: Set the MI Driver's exit application flag. The application checks // this flag // after every stdin line is read so the exit may not be instantaneous. @@ -1049,7 +1011,6 @@ void CMIDriver::SetExitApplicationFlag(const bool vbForceExit) { } //++ -//------------------------------------------------------------------------------------ // Details: Get the MI Driver's exit exit application flag. // This is related to the running state of the MI driver. // Type: Method. @@ -1061,7 +1022,6 @@ void CMIDriver::SetExitApplicationFlag(const bool vbForceExit) { bool CMIDriver::GetExitApplicationFlag() const { return m_bExitApp; } //++ -//------------------------------------------------------------------------------------ // Details: Get the current running state of the MI Driver. // Type: Method. // Args: None. @@ -1073,7 +1033,6 @@ CMIDriver::DriverState_e CMIDriver::GetCurrentDriverState() const { } //++ -//------------------------------------------------------------------------------------ // Details: Set the current running state of the MI Driver to running and // currently not in // a debug session. @@ -1120,7 +1079,6 @@ bool CMIDriver::SetDriverStateRunningNotDebugging() { } //++ -//------------------------------------------------------------------------------------ // Details: Set the current running state of the MI Driver to running and // currently not in // a debug session. The driver's state must in the state running and in @@ -1169,7 +1127,6 @@ bool CMIDriver::SetDriverStateRunningDebugging() { } //++ -//------------------------------------------------------------------------------------ // Details: Prepare the client IDE so it will start working/communicating with // *this MI // driver. @@ -1185,7 +1142,6 @@ bool CMIDriver::InitClientIDEToMIDriver() const { } //++ -//------------------------------------------------------------------------------------ // Details: The IDE Eclipse when debugging locally expects "(gdb)\n" character // sequence otherwise it refuses to communicate and times out. This // should be @@ -1201,7 +1157,6 @@ bool CMIDriver::InitClientIDEEclipse() const { } //++ -//------------------------------------------------------------------------------------ // Details: Ask *this driver whether it found an executable in the MI Driver's // list of // arguments which to open and debug. If so instigate commands to set @@ -1220,7 +1175,6 @@ bool CMIDriver::HaveExecutableFileNamePathOnCmdLine() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve from *this driver executable file name path to start a // debug session // with (if present see HaveExecutableFileNamePathOnCmdLine()). @@ -1234,7 +1188,6 @@ const CMIUtilString &CMIDriver::GetExecutableFileNamePathOnCmdLine() const { } //++ -//------------------------------------------------------------------------------------ // Details: Execute commands (by injecting them into the stdin line queue // container) and // other code to set up the MI Driver such that is can take the @@ -1257,7 +1210,6 @@ bool CMIDriver::LocalDebugSessionStartupExecuteCommands() { } //++ -//------------------------------------------------------------------------------------ // Details: Set the MI Driver into "its debugging an executable passed as an // argument" // mode as against running via a client like Eclipse. @@ -1271,7 +1223,6 @@ void CMIDriver::SetDriverDebuggingArgExecutable() { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the MI Driver state indicating if it is operating in "its // debugging // an executable passed as an argument" mode as against running via a @@ -1287,7 +1238,6 @@ bool CMIDriver::IsDriverDebuggingArgExecutable() const { } //++ -//------------------------------------------------------------------------------------ // Details: Execute commands from command source file in specified mode, and // set exit-flag if needed. // Type: Method. @@ -1353,7 +1303,6 @@ bool CMIDriver::ExecuteCommandFile(const bool vbAsyncMode) { } //++ -//------------------------------------------------------------------------------------ // Details: Gets called when lldb-mi gets a signal. Stops the process if it was // SIGINT. // diff --git a/tools/lldb-mi/MIDriver.h b/tools/lldb-mi/MIDriver.h index 1b5865697da7..03bbb3e75151 100644 --- a/tools/lldb-mi/MIDriver.h +++ b/tools/lldb-mi/MIDriver.h @@ -1,9 +1,8 @@ //===-- MIDriver.h ----------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MIDriverBase.cpp b/tools/lldb-mi/MIDriverBase.cpp index f70da6ea08e1..b8844e288430 100644 --- a/tools/lldb-mi/MIDriverBase.cpp +++ b/tools/lldb-mi/MIDriverBase.cpp @@ -1,9 +1,8 @@ //===-- MIDriverBase.cpp ----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -15,7 +14,6 @@ #include "MIDriverBase.h" //++ -//------------------------------------------------------------------------------------ // Details: CMIDriverBase constructor. // Type: Method. // Args: None. @@ -26,17 +24,15 @@ CMIDriverBase::CMIDriverBase() : m_pDriverFallThru(nullptr), m_pDriverParent(nullptr), m_bExitApp(false) {} //++ -//------------------------------------------------------------------------------------ // Details: CMIDriverBase destructor. // Type: Overrideable. // Args: None. // Return: None. // Throws: None. //-- -CMIDriverBase::~CMIDriverBase() { m_pDriverFallThru = NULL; } +CMIDriverBase::~CMIDriverBase() { m_pDriverFallThru = nullptr; } //++ -//------------------------------------------------------------------------------------ // Details: This function allows *this driver to call on another driver to // perform work // should this driver not be able to handle the client data input. @@ -56,7 +52,6 @@ bool CMIDriverBase::DoFallThruToAnotherDriver(const CMIUtilString &vCmd, } //++ -//------------------------------------------------------------------------------------ // Details: This function allows *this driver to call on another driver to // perform work // should this driver not be able to handle the client data input. @@ -75,7 +70,6 @@ bool CMIDriverBase::SetDriverToFallThruTo(const CMIDriverBase &vrOtherDriver) { } //++ -//------------------------------------------------------------------------------------ // Details: This function allows *this driver to call functionality on the // parent driver // ask for information for example. @@ -94,7 +88,6 @@ bool CMIDriverBase::SetDriverParent(const CMIDriverBase &vrOtherDriver) { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the parent driver to *this driver if one assigned. If // assigned *this // is the pass through driver that the parent driver passes work to. @@ -109,7 +102,6 @@ CMIDriverBase *CMIDriverBase::GetDriversParent() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the pointer to the other fall through driver *this driver // is using // (or not using). @@ -124,7 +116,6 @@ CMIDriverBase *CMIDriverBase::GetDriverToFallThruTo() const { } //++ -//------------------------------------------------------------------------------------ // Details: *this driver provides a file stream to other drivers on which *this // driver // write's out to and they read as expected input. *this driver is @@ -141,7 +132,6 @@ FILE *CMIDriverBase::GetStdin() const { } //++ -//------------------------------------------------------------------------------------ // Details: *this driver provides a file stream to other pass through assigned // drivers // so they know what to write to. @@ -156,7 +146,6 @@ FILE *CMIDriverBase::GetStdout() const { } //++ -//------------------------------------------------------------------------------------ // Details: *this driver provides a error file stream to other pass through // assigned drivers // so they know what to write to. @@ -171,7 +160,6 @@ FILE *CMIDriverBase::GetStderr() const { } //++ -//------------------------------------------------------------------------------------ // Details: Set the MI Driver's exit application flag. The application checks // this flag // after every stdin line is read so the exit may not be instantaneous. diff --git a/tools/lldb-mi/MIDriverBase.h b/tools/lldb-mi/MIDriverBase.h index 8ac49ecd88df..aec306e4b40a 100644 --- a/tools/lldb-mi/MIDriverBase.h +++ b/tools/lldb-mi/MIDriverBase.h @@ -1,9 +1,8 @@ //===-- MIDriverBase.h ------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MIDriverMain.cpp b/tools/lldb-mi/MIDriverMain.cpp index d347ecbbebeb..8bc4571a458d 100644 --- a/tools/lldb-mi/MIDriverMain.cpp +++ b/tools/lldb-mi/MIDriverMain.cpp @@ -1,9 +1,8 @@ //===-- MIDriverMain.cpp ----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -52,7 +51,6 @@ // CODETAG_IOR_SIGNALS //++ -//------------------------------------------------------------------------------------ // Details: The SIGINT signal is sent to a process by its controlling terminal // when a // user wishes to interrupt the process. This is typically initiated by @@ -86,7 +84,6 @@ void sigint_handler(int vSigno) { } //++ -//------------------------------------------------------------------------------------ // Details: Init the MI driver system. Initialize the whole driver system which // includes // both the original LLDB driver and the MI driver. @@ -112,7 +109,6 @@ bool DriverSystemInit() { } //++ -//------------------------------------------------------------------------------------ // Details: Shutdown the debugger system. Release / terminate resources external // to // specifically the MI driver. @@ -132,7 +128,6 @@ bool DriverSystemShutdown(const bool vbAppExitOk) { } //++ -//------------------------------------------------------------------------------------ // Details: MI's application start point of execution. The application runs in // two modes. // An LLDB native driver mode where it acts no different from the LLDB diff --git a/tools/lldb-mi/MIDriverMgr.cpp b/tools/lldb-mi/MIDriverMgr.cpp index 93070a5912d6..26195cdb7414 100644 --- a/tools/lldb-mi/MIDriverMgr.cpp +++ b/tools/lldb-mi/MIDriverMgr.cpp @@ -1,9 +1,8 @@ //===-- MIDriverMgr.cpp -----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -20,7 +19,6 @@ #include "MIUtilSingletonHelper.h" //++ -//------------------------------------------------------------------------------------ // Details: CMIDriverMgr constructor. // Type: Method. // Args: None. @@ -30,7 +28,6 @@ CMIDriverMgr::CMIDriverMgr() : m_pDriverCurrent(nullptr), m_bInMi2Mode(false) {} //++ -//------------------------------------------------------------------------------------ // Details: CMIDriverMgr destructor. // Type: Overridden. // Args: None. @@ -40,7 +37,6 @@ CMIDriverMgr::CMIDriverMgr() : m_pDriverCurrent(nullptr), m_bInMi2Mode(false) {} CMIDriverMgr::~CMIDriverMgr() { Shutdown(); } //++ -//------------------------------------------------------------------------------------ // Details: Initialize *this manager. // Type: Method. // Args: None. @@ -77,7 +73,6 @@ bool CMIDriverMgr::Initialize() { } //++ -//------------------------------------------------------------------------------------ // Details: Unbind detach or release resources used by this server in general // common // functionality shared between versions of any server interfaces @@ -120,7 +115,6 @@ bool CMIDriverMgr::Shutdown() { return bOk; } //++ -//------------------------------------------------------------------------------------ // Details: Unregister all the Driver registered with *this manager. The manager // also // deletes @@ -141,13 +135,12 @@ bool CMIDriverMgr::UnregisterDriverAll() { } m_mapDriverIdToDriver.clear(); - m_pDriverCurrent = NULL; + m_pDriverCurrent = nullptr; return MIstatus::success; } //++ -//------------------------------------------------------------------------------------ // Details: Register a driver with *this Driver Manager. Call // SetUseThisDriverToDoWork() // inform the manager which driver is the one to the work. The manager @@ -184,7 +177,6 @@ bool CMIDriverMgr::RegisterDriver(const IDriver &vrDriver, } //++ -//------------------------------------------------------------------------------------ // Details: Query the Driver Manager to see if *this manager has the driver // already // registered. @@ -209,7 +201,6 @@ bool CMIDriverMgr::HaveDriverAlready(const IDriver &vrDriver) const { } //++ -//------------------------------------------------------------------------------------ // Details: Unregister a driver from the Driver Manager. Call the // SetUseThisDriverToDoWork() // function to define another driver to do work if the one being @@ -241,7 +232,6 @@ bool CMIDriverMgr::UnregisterDriver(const IDriver &vrDriver) { } //++ -//------------------------------------------------------------------------------------ // Details: Specify the driver to do work. The Driver Manager drives this // driver. Any // previous driver doing work is not called anymore (so be sure the @@ -267,7 +257,6 @@ bool CMIDriverMgr::SetUseThisDriverToDoWork(const IDriver &vrADriver) { } //++ -//------------------------------------------------------------------------------------ // Details: Ask *this manager which driver is currently doing the work. // Type: Method. // Args: None. @@ -280,7 +269,6 @@ CMIDriverMgr::IDriver *CMIDriverMgr::GetUseThisDriverToDoWork() const { } //++ -//------------------------------------------------------------------------------------ // Details: Call this function puts *this driver to work. // Type: Method. // Args: None. @@ -307,7 +295,6 @@ bool CMIDriverMgr::DriverMainLoop() { } //++ -//------------------------------------------------------------------------------------ // Details: Get the current driver to validate executable command line // arguments. // Type: Method. @@ -357,7 +344,6 @@ bool CMIDriverMgr::DriverParseArgs(const int argc, const char *argv[], } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the current driver's last error condition. // Type: Method. // Args: None. @@ -376,7 +362,6 @@ CMIUtilString CMIDriverMgr::DriverGetError() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the current driver's name. // Type: Method. // Args: None. @@ -396,7 +381,6 @@ CMIUtilString CMIDriverMgr::DriverGetName() const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the current driver's debugger object. // Type: Method. // Args: None. @@ -417,7 +401,6 @@ lldb::SBDebugger *CMIDriverMgr::DriverGetTheDebugger() { } //++ -//------------------------------------------------------------------------------------ // Details: Check the arguments given on the command line. The main purpose of // this // function is to check for the presence of the --interpreter option. @@ -494,7 +477,8 @@ bool CMIDriverMgr::ParseArgs(const int argc, const char *argv[], bOk = bOk && m_pLog->Write(strArgs, CMICmnLog::eLogVerbosity_Log); } else { for (MIint i = 1; i < argc; i++) { - strArgs += CMIUtilString::Format("%d:'%s' ", i, argv[i]); + strArgs += CMIUtilString::Format("%d:'%s' ", i, + CMIUtilString::WithNullAsEmpty(argv[i])); } bOk = bOk && m_pLog->Write(strArgs, CMICmnLog::eLogVerbosity_Log); } @@ -605,7 +589,6 @@ bool CMIDriverMgr::ParseArgs(const int argc, const char *argv[], } //++ -//------------------------------------------------------------------------------------ // Details: Return formatted application version and name information. // Type: Method. // Args: None. @@ -623,7 +606,6 @@ CMIUtilString CMIDriverMgr::GetAppVersion() const { } //++ -//------------------------------------------------------------------------------------ // Details: Return formatted help information on all the MI command line // options. // Type: Method. @@ -655,7 +637,6 @@ CMIUtilString CMIDriverMgr::GetHelpOnCmdLineArgOptions() const { } //++ -//------------------------------------------------------------------------------------ // Details: Search the registered drivers and return the first driver which says // it is // GDB/MI compatible i.e. the CMIDriver class. @@ -684,7 +665,6 @@ CMIDriverMgr::IDriver *CMIDriverMgr::GetFirstMIDriver() const { } //++ -//------------------------------------------------------------------------------------ // Details: Search the registered drivers and return the first driver which says // it is // not GDB/MI compatible i.e. the LLDB Driver class. @@ -713,7 +693,6 @@ CMIDriverMgr::IDriver *CMIDriverMgr::GetFirstNonMIDriver() const { } //++ -//------------------------------------------------------------------------------------ // Details: Search the registered drivers and return driver with the specified // ID. // Type: Method. @@ -734,7 +713,6 @@ CMIDriverMgr::GetDriver(const CMIUtilString &vrDriverId) const { } //++ -//------------------------------------------------------------------------------------ // Details: Gets called when lldb-mi gets a signal. Passed signal to current // driver. // diff --git a/tools/lldb-mi/MIDriverMgr.h b/tools/lldb-mi/MIDriverMgr.h index dbdc4194e19d..a7a1dbbb9bf2 100644 --- a/tools/lldb-mi/MIDriverMgr.h +++ b/tools/lldb-mi/MIDriverMgr.h @@ -1,9 +1,8 @@ //===-- MIDriverMgr.h -------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MIUtilDateTimeStd.cpp b/tools/lldb-mi/MIUtilDateTimeStd.cpp index e06eadd6b6a0..e92250a4f2d2 100644 --- a/tools/lldb-mi/MIUtilDateTimeStd.cpp +++ b/tools/lldb-mi/MIUtilDateTimeStd.cpp @@ -1,9 +1,8 @@ //===-- MIUtilDateTimeStd.cpp -----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -12,7 +11,6 @@ #include "MICmnResources.h" //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilDateTimeStd constructor. // Type: Method. // Args: None. @@ -22,7 +20,6 @@ CMIUtilDateTimeStd::CMIUtilDateTimeStd() {} //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilDateTimeStd destructor. // Type: Method. // Args: None. @@ -32,7 +29,6 @@ CMIUtilDateTimeStd::CMIUtilDateTimeStd() {} CMIUtilDateTimeStd::~CMIUtilDateTimeStd() {} //++ -//------------------------------------------------------------------------------------ // Details: Retrieve system local current date. Format is MM/DD/YYYY. // Type: Method. // Args: None. @@ -51,7 +47,6 @@ CMIUtilString CMIUtilDateTimeStd::GetDate() { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve system local current time. Format is HH:MM:SS 24 hour // clock. // Type: Method. @@ -71,7 +66,6 @@ CMIUtilString CMIUtilDateTimeStd::GetTime() { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve system local current date and time in yyyy-MM-dd--HH-mm-ss // format for log file names. // Type: Method. diff --git a/tools/lldb-mi/MIUtilDateTimeStd.h b/tools/lldb-mi/MIUtilDateTimeStd.h index 7afece807ebf..1a8e30c5654f 100644 --- a/tools/lldb-mi/MIUtilDateTimeStd.h +++ b/tools/lldb-mi/MIUtilDateTimeStd.h @@ -1,9 +1,8 @@ //===-- MIUtilDateTimeStd.h -------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MIUtilDebug.cpp b/tools/lldb-mi/MIUtilDebug.cpp index 598a1a71046b..4b418f390ca7 100644 --- a/tools/lldb-mi/MIUtilDebug.cpp +++ b/tools/lldb-mi/MIUtilDebug.cpp @@ -1,9 +1,8 @@ //===-- MIUtilDebug.cpp -----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -18,7 +17,6 @@ #include "MIUtilDebug.h" //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilDebug constructor. // Type: Method. // Args: None. @@ -28,7 +26,6 @@ CMIUtilDebug::CMIUtilDebug() {} //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilDebug destructor. // Type: Method. // Args: None. @@ -38,7 +35,6 @@ CMIUtilDebug::CMIUtilDebug() {} CMIUtilDebug::~CMIUtilDebug() {} //++ -//------------------------------------------------------------------------------------ // Details: Temporarily stall the process/application to give the programmer the // opportunity to attach a debugger. How to use: Put a break in the // programmer @@ -62,16 +58,12 @@ void CMIUtilDebug::WaitForDbgAttachInfinteLoop() { } } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- // Instantiations: CMICmnLog &CMIUtilDebugFnTrace::ms_rLog = CMICmnLog::Instance(); MIuint CMIUtilDebugFnTrace::ms_fnDepthCnt = 0; //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilDebugFnTrace constructor. // Type: Method. // Args: vFnName - (R) The text to insert into the log. @@ -86,7 +78,6 @@ CMIUtilDebugFnTrace::CMIUtilDebugFnTrace(const CMIUtilString &vFnName) } //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilDebugFnTrace destructor. // Type: Method. // Args: None. diff --git a/tools/lldb-mi/MIUtilDebug.h b/tools/lldb-mi/MIUtilDebug.h index 16b080ee7b62..537907ae304f 100644 --- a/tools/lldb-mi/MIUtilDebug.h +++ b/tools/lldb-mi/MIUtilDebug.h @@ -1,9 +1,8 @@ //===-- MIUtilDebug.h -------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MIUtilFileStd.cpp b/tools/lldb-mi/MIUtilFileStd.cpp index abf0ef407d3b..2d8a05985e59 100644 --- a/tools/lldb-mi/MIUtilFileStd.cpp +++ b/tools/lldb-mi/MIUtilFileStd.cpp @@ -1,9 +1,8 @@ //===-- MIUtilFileStd.cpp ---------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -19,9 +18,9 @@ #include "lldb/Host/FileSystem.h" #include "llvm/Support/ConvertUTF.h" +#include "llvm/Support/Errno.h" //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilFileStd constructor. // Type: Method. // Args: None. @@ -42,7 +41,6 @@ CMIUtilFileStd::CMIUtilFileStd() } //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilFileStd destructor. // Type: Method. // Args: None. @@ -52,7 +50,6 @@ CMIUtilFileStd::CMIUtilFileStd() CMIUtilFileStd::~CMIUtilFileStd() { Close(); } //++ -//------------------------------------------------------------------------------------ // Details: Open file for writing. On the first call to this function after // *this object // is created the file is either created or replace, from then on open @@ -84,7 +81,8 @@ bool CMIUtilFileStd::CreateWrite(const CMIUtilString &vFileNamePath, #if !defined(_MSC_VER) // Open with 'write' and 'binary' mode - m_pFileHandle = ::fopen(vFileNamePath.c_str(), "wb"); + m_pFileHandle = llvm::sys::RetryAfterSignal(nullptr, ::fopen, + vFileNamePath.c_str(), "wb"); #else // Open a file with exclusive write and shared read permissions std::wstring path; @@ -110,7 +108,6 @@ bool CMIUtilFileStd::CreateWrite(const CMIUtilString &vFileNamePath, } //++ -//------------------------------------------------------------------------------------ // Details: Write data to existing opened file. // Type: Method. // Args: vData - (R) Text data. @@ -148,7 +145,6 @@ bool CMIUtilFileStd::Write(const CMIUtilString &vData) { } //++ -//------------------------------------------------------------------------------------ // Details: Write data to existing opened file. // Type: Method. // Args: vData - (R) Text data. @@ -185,7 +181,6 @@ bool CMIUtilFileStd::Write(const char *vpData, const MIuint vCharCnt) { } //++ -//------------------------------------------------------------------------------------ // Details: Close existing opened file. Note Close() must must an open! // Type: Method. // Args: None. @@ -203,7 +198,6 @@ void CMIUtilFileStd::Close() { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve state of whether the file is ok. // Type: Method. // Args: None. @@ -214,7 +208,6 @@ void CMIUtilFileStd::Close() { bool CMIUtilFileStd::IsOk() const { return !m_bFileError; } //++ -//------------------------------------------------------------------------------------ // Details: Status on a file existing already. // Type: Method. // Args: vFileNamePath. @@ -227,7 +220,8 @@ bool CMIUtilFileStd::IsFileExist(const CMIUtilString &vFileNamePath) const { return false; FILE *pTmp = nullptr; - pTmp = ::fopen(vFileNamePath.c_str(), "wb"); + pTmp = llvm::sys::RetryAfterSignal(nullptr, ::fopen, + vFileNamePath.c_str(), "wb"); if (pTmp != nullptr) { ::fclose(pTmp); return true; @@ -237,7 +231,6 @@ bool CMIUtilFileStd::IsFileExist(const CMIUtilString &vFileNamePath) const { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the file current carriage line return characters used. // Type: Method. // Args: None. @@ -249,7 +242,6 @@ const CMIUtilString &CMIUtilFileStd::GetLineReturn() const { } //++ -//------------------------------------------------------------------------------------ // Details: Given a file name directory path, strip off the filename and return // the path. // It look for either backslash or forward slash. @@ -273,7 +265,6 @@ CMIUtilFileStd::StripOffFileName(const CMIUtilString &vDirectoryPath) { } //++ -//------------------------------------------------------------------------------------ // Details: Return either backslash or forward slash appropriate to the OS this // application // is running on. diff --git a/tools/lldb-mi/MIUtilFileStd.h b/tools/lldb-mi/MIUtilFileStd.h index 2120cc25e8a0..e2e590b6aaf4 100644 --- a/tools/lldb-mi/MIUtilFileStd.h +++ b/tools/lldb-mi/MIUtilFileStd.h @@ -1,9 +1,8 @@ //===-- MIUtilFileStd.h -----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MIUtilMapIdToVariant.cpp b/tools/lldb-mi/MIUtilMapIdToVariant.cpp index 0a4e7299e926..9361cedab3e7 100644 --- a/tools/lldb-mi/MIUtilMapIdToVariant.cpp +++ b/tools/lldb-mi/MIUtilMapIdToVariant.cpp @@ -1,9 +1,8 @@ //===-- MIUtilMapIdToVariant.cpp --------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -11,7 +10,6 @@ #include "MIUtilMapIdToVariant.h" //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilMapIdToVariant constructor. // Type: Method. // Args: None. @@ -21,7 +19,6 @@ CMIUtilMapIdToVariant::CMIUtilMapIdToVariant() {} //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilMapIdToVariant destructor. // Type: Method. // Args: None. @@ -31,7 +28,6 @@ CMIUtilMapIdToVariant::CMIUtilMapIdToVariant() {} CMIUtilMapIdToVariant::~CMIUtilMapIdToVariant() {} //++ -//------------------------------------------------------------------------------------ // Details: Remove at the data from *this container. // Type: Method. // Args: None. @@ -41,7 +37,6 @@ CMIUtilMapIdToVariant::~CMIUtilMapIdToVariant() {} void CMIUtilMapIdToVariant::Clear() { m_mapKeyToVariantValue.clear(); } //++ -//------------------------------------------------------------------------------------ // Details: Check an ID is present already in *this container. // Type: Method. // Args: vId - (R) Unique ID i.e. GUID. @@ -56,7 +51,6 @@ bool CMIUtilMapIdToVariant::HaveAlready(const CMIUtilString &vId) const { } //++ -//------------------------------------------------------------------------------------ // Details: Determine if *this container is currently holding any data. // Type: Method. // Args: None. @@ -68,7 +62,6 @@ bool CMIUtilMapIdToVariant::IsEmpty() const { } //++ -//------------------------------------------------------------------------------------ // Details: Check the ID is valid to be registered. // Type: Method. // Args: vId - (R) Unique ID i.e. GUID. @@ -86,7 +79,6 @@ bool CMIUtilMapIdToVariant::IsValid(const CMIUtilString &vId) const { } //++ -//------------------------------------------------------------------------------------ // Details: Remove from *this contain a data object specified by ID. The data // object // when removed also calls its destructor should it have one. diff --git a/tools/lldb-mi/MIUtilMapIdToVariant.h b/tools/lldb-mi/MIUtilMapIdToVariant.h index a56477c4dba9..ba3e176e0c41 100644 --- a/tools/lldb-mi/MIUtilMapIdToVariant.h +++ b/tools/lldb-mi/MIUtilMapIdToVariant.h @@ -1,9 +1,8 @@ //===-- MIUtilMapIdToVariant.h ----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -56,7 +55,6 @@ private: }; //++ -//------------------------------------------------------------------------------------ // Details: Add to *this container a data object of general type identified by // an ID. // If the data with that ID already exists in the container it is @@ -90,7 +88,6 @@ bool CMIUtilMapIdToVariant::Add(const CMIUtilString &vId, const T &vData) { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve a data object from *this container identified by the // specified ID. // Type: Method. diff --git a/tools/lldb-mi/MIUtilSingletonBase.h b/tools/lldb-mi/MIUtilSingletonBase.h index d73627307e5f..e76fff72b27c 100644 --- a/tools/lldb-mi/MIUtilSingletonBase.h +++ b/tools/lldb-mi/MIUtilSingletonBase.h @@ -1,9 +1,8 @@ //===-- MIUtilSingletonBase.h -----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MIUtilSingletonHelper.h b/tools/lldb-mi/MIUtilSingletonHelper.h index 831c60aecfef..b9ac61a58e7f 100644 --- a/tools/lldb-mi/MIUtilSingletonHelper.h +++ b/tools/lldb-mi/MIUtilSingletonHelper.h @@ -1,9 +1,8 @@ //===-- MIUtilSingletonHelper.h ---------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MIUtilString.cpp b/tools/lldb-mi/MIUtilString.cpp index 627c2f3d4d3b..986de963450e 100644 --- a/tools/lldb-mi/MIUtilString.cpp +++ b/tools/lldb-mi/MIUtilString.cpp @@ -1,9 +1,8 @@ //===-- MIUtilString.cpp ----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -21,7 +20,6 @@ #include "MIUtilString.h" //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilString constructor. // Type: Method. // Args: None. @@ -31,17 +29,16 @@ CMIUtilString::CMIUtilString() : std::string() {} //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilString constructor. // Type: Method. // Args: vpData - Pointer to UTF8 text data. // Return: None. // Throws: None. //-- -CMIUtilString::CMIUtilString(const char *vpData) : std::string(vpData) {} +CMIUtilString::CMIUtilString(const char *vpData) + : std::string(WithNullAsEmpty(vpData)) {} //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilString constructor. // Type: Method. // Args: vpStr - Text data. @@ -51,7 +48,6 @@ CMIUtilString::CMIUtilString(const char *vpData) : std::string(vpData) {} CMIUtilString::CMIUtilString(const std::string &vrStr) : std::string(vrStr) {} //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilString assignment operator. // Type: Method. // Args: vpRhs - Pointer to UTF8 text data. @@ -59,12 +55,11 @@ CMIUtilString::CMIUtilString(const std::string &vrStr) : std::string(vrStr) {} // Throws: None. //-- CMIUtilString &CMIUtilString::operator=(const char *vpRhs) { - assign(vpRhs); + assign(WithNullAsEmpty(vpRhs)); return *this; } //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilString assignment operator. // Type: Method. // Args: vrRhs - The other string to copy from. @@ -77,7 +72,6 @@ CMIUtilString &CMIUtilString::operator=(const std::string &vrRhs) { } //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilString destructor. // Type: Method. // Args: None. @@ -87,7 +81,6 @@ CMIUtilString &CMIUtilString::operator=(const std::string &vrRhs) { CMIUtilString::~CMIUtilString() {} //++ -//------------------------------------------------------------------------------------ // Details: Perform a snprintf format style on a string data. A new string // object is // created and returned. @@ -104,12 +97,10 @@ CMIUtilString CMIUtilString::FormatPriv(const CMIUtilString &vrFormat, MIint n = vrFormat.size(); // IOR: mysterious crash in this function on some windows builds not able to - // duplicate - // but found article which may be related. Crash occurs in vsnprintf() or - // va_copy() + // duplicate but found article which may be related. Crash occurs in + // vsnprintf() or va_copy(). // Duplicate vArgs va_list argument pointer to ensure that it can be safely - // used in - // a new frame + // used in a new frame. // http://julipedia.meroh.net/2011/09/using-vacopy-to-safely-pass-ap.html va_list argsDup; va_copy(argsDup, vArgs); @@ -128,8 +119,8 @@ CMIUtilString CMIUtilString::FormatPriv(const CMIUtilString &vrFormat, pFormatted.reset(new char[n + 1]); // +1 for safety margin ::strncpy(&pFormatted[0], vrFormat.c_str(), n); - // We need to restore the variable argument list pointer to the start again - // before running vsnprintf() more then once + // We need to restore the variable argument list pointer to the start again + // before running vsnprintf() more then once va_copy(argsDup, argsCpy); nFinal = ::vsnprintf(&pFormatted[0], n, vrFormat.c_str(), argsDup); @@ -148,7 +139,6 @@ CMIUtilString CMIUtilString::FormatPriv(const CMIUtilString &vrFormat, } //++ -//------------------------------------------------------------------------------------ // Details: Perform a snprintf format style on a string data. A new string // object is // created and returned. @@ -161,14 +151,14 @@ CMIUtilString CMIUtilString::FormatPriv(const CMIUtilString &vrFormat, CMIUtilString CMIUtilString::Format(const char *vFormating, ...) { va_list args; va_start(args, vFormating); - CMIUtilString strResult = CMIUtilString::FormatPriv(vFormating, args); + CMIUtilString strResult = + CMIUtilString::FormatPriv(WithNullAsEmpty(vFormating), args); va_end(args); return strResult; } //++ -//------------------------------------------------------------------------------------ // Details: Perform a snprintf format style on a string data. A new string // object is // created and returned. @@ -184,7 +174,6 @@ CMIUtilString CMIUtilString::FormatValist(const CMIUtilString &vrFormating, } //++ -//------------------------------------------------------------------------------------ // Details: Splits string into array of strings using delimiter. If multiple // delimiter // are found in sequence then they are not added to the list of splits. @@ -228,7 +217,6 @@ size_t CMIUtilString::Split(const CMIUtilString &vDelimiter, } //++ -//------------------------------------------------------------------------------------ // Details: Splits string into array of strings using delimiter. However the // string is // also considered for text surrounded by quotes. Text with quotes @@ -287,7 +275,6 @@ size_t CMIUtilString::SplitConsiderQuotes(const CMIUtilString &vDelimiter, } //++ -//------------------------------------------------------------------------------------ // Details: Split string into lines using \n and return an array of strings. // Type: Method. // Args: vwVecSplits - (W) Container of splits found in string data. @@ -299,7 +286,6 @@ size_t CMIUtilString::SplitLines(VecString_t &vwVecSplits) const { } //++ -//------------------------------------------------------------------------------------ // Details: Remove '\n' from the end of string if found. It does not alter // *this string. // Type: Method. @@ -318,7 +304,6 @@ CMIUtilString CMIUtilString::StripCREndOfLine() const { } //++ -//------------------------------------------------------------------------------------ // Details: Remove all '\n' from the string and replace with a space. It does // not alter // *this string. @@ -332,7 +317,6 @@ CMIUtilString CMIUtilString::StripCRAll() const { } //++ -//------------------------------------------------------------------------------------ // Details: Find and replace all matches of a sub string with another string. It // does not // alter *this string. @@ -363,7 +347,6 @@ CMIUtilString::FindAndReplace(const CMIUtilString &vFind, } //++ -//------------------------------------------------------------------------------------ // Details: Check if *this string is a decimal number. // Type: Method. // Args: None. @@ -382,7 +365,6 @@ bool CMIUtilString::IsNumber() const { } //++ -//------------------------------------------------------------------------------------ // Details: Check if *this string is a hexadecimal number. // Type: Method. // Args: None. @@ -400,7 +382,6 @@ bool CMIUtilString::IsHexadecimalNumber() const { } //++ -//------------------------------------------------------------------------------------ // Details: Extract the number from the string. The number can be either a // hexadecimal or // natural number. It cannot contain other non-numeric characters. @@ -423,7 +404,6 @@ bool CMIUtilString::ExtractNumber(MIint64 &vwrNumber) const { } //++ -//------------------------------------------------------------------------------------ // Details: Extract the number from the hexadecimal string.. // Type: Method. // Args: vwrNumber - (W) Number extracted from the string. @@ -448,7 +428,6 @@ bool CMIUtilString::ExtractNumberFromHexadecimal(MIint64 &vwrNumber) const { } //++ -//------------------------------------------------------------------------------------ // Details: Determine if the text is all valid alpha numeric characters. Letters // can be // either upper or lower case. @@ -458,7 +437,7 @@ bool CMIUtilString::ExtractNumberFromHexadecimal(MIint64 &vwrNumber) const { // Throws: None. //-- bool CMIUtilString::IsAllValidAlphaAndNumeric(const char *vpText) { - const size_t len = ::strlen(vpText); + const size_t len = ::strlen(WithNullAsEmpty(vpText)); if (len == 0) return false; @@ -472,7 +451,6 @@ bool CMIUtilString::IsAllValidAlphaAndNumeric(const char *vpText) { } //++ -//------------------------------------------------------------------------------------ // Details: Check if two strings share equal contents. // Type: Method. // Args: vrLhs - (R) String A. @@ -490,7 +468,6 @@ bool CMIUtilString::Compare(const CMIUtilString &vrLhs, } //++ -//------------------------------------------------------------------------------------ // Details: Remove from either end of *this string the following: " \t\n\v\f\r". // Type: Method. // Args: None. @@ -513,7 +490,6 @@ CMIUtilString CMIUtilString::Trim() const { } //++ -//------------------------------------------------------------------------------------ // Details: Remove from either end of *this string the specified character. // Type: Method. // Args: None. @@ -532,7 +508,6 @@ CMIUtilString CMIUtilString::Trim(const char vChar) const { } //++ -//------------------------------------------------------------------------------------ // Details: Do a printf equivalent for printing a number in binary i.e. "b%llB". // Type: Static method. // Args: vnDecimal - (R) The number to represent in binary. @@ -565,7 +540,6 @@ CMIUtilString CMIUtilString::FormatBinary(const MIuint64 vnDecimal) { } //++ -//------------------------------------------------------------------------------------ // Details: Remove from a string doubled up characters so only one set left. // Characters // are only removed if the previous character is already a same @@ -581,7 +555,6 @@ CMIUtilString CMIUtilString::RemoveRepeatedCharacters(const char vChar) { } //++ -//------------------------------------------------------------------------------------ // Details: Recursively remove from a string doubled up characters so only one // set left. // Characters are only removed if the previous character is already a @@ -616,7 +589,6 @@ CMIUtilString CMIUtilString::RemoveRepeatedCharacters(size_t vnPos, } //++ -//------------------------------------------------------------------------------------ // Details: Is the text in *this string surrounded by quotes. // Type: Method. // Args: None. @@ -634,7 +606,6 @@ bool CMIUtilString::IsQuoted() const { } //++ -//------------------------------------------------------------------------------------ // Details: Find first occurrence in *this string which matches the pattern. // Type: Method. // Args: vrPattern - (R) The pattern to search for. @@ -649,7 +620,6 @@ size_t CMIUtilString::FindFirst(const CMIUtilString &vrPattern, } //++ -//------------------------------------------------------------------------------------ // Details: Find first occurrence in *this string which matches the pattern and // isn't surrounded by quotes. // Type: Method. @@ -698,7 +668,6 @@ size_t CMIUtilString::FindFirst(const CMIUtilString &vrPattern, } //++ -//------------------------------------------------------------------------------------ // Details: Find first occurrence in *this string which doesn't match the // pattern. // Type: Method. @@ -725,7 +694,6 @@ size_t CMIUtilString::FindFirstNot(const CMIUtilString &vrPattern, } //++ -//------------------------------------------------------------------------------------ // Details: Find first occurrence of not escaped quotation mark in *this string. // Type: Method. // Args: vnPos - Position of the first character in the string to be @@ -756,7 +724,6 @@ size_t CMIUtilString::FindFirstQuote(size_t vnPos) const { } //++ -//------------------------------------------------------------------------------------ // Details: Get escaped string from *this string. // Type: Method. // Args: None. @@ -778,7 +745,6 @@ CMIUtilString CMIUtilString::Escape(bool vbEscapeQuotes /* = false */) const { } //++ -//------------------------------------------------------------------------------------ // Details: Get string with backslashes in front of double quote '"' and // backslash '\\' // characters. @@ -814,7 +780,6 @@ CMIUtilString CMIUtilString::AddSlashes() const { } //++ -//------------------------------------------------------------------------------------ // Details: Remove backslashes added by CMIUtilString::AddSlashes. // Type: Method. // Args: None. diff --git a/tools/lldb-mi/MIUtilString.h b/tools/lldb-mi/MIUtilString.h index 2639141d0fb2..e9d3af7a6225 100644 --- a/tools/lldb-mi/MIUtilString.h +++ b/tools/lldb-mi/MIUtilString.h @@ -1,9 +1,8 @@ //===-- MIUtilString.h ------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -35,6 +34,9 @@ public: static CMIUtilString FormatValist(const CMIUtilString &vrFormating, va_list vArgs); static bool IsAllValidAlphaAndNumeric(const char *vpText); + static const char *WithNullAsEmpty(const char *vpText) { + return vpText ? vpText : ""; + } static bool Compare(const CMIUtilString &vrLhs, const CMIUtilString &vrRhs); static CMIUtilString ConvertToPrintableASCII(const char vChar, bool bEscapeQuotes = false); diff --git a/tools/lldb-mi/MIUtilThreadBaseStd.cpp b/tools/lldb-mi/MIUtilThreadBaseStd.cpp index 85780083a5a5..72cf1474a78b 100644 --- a/tools/lldb-mi/MIUtilThreadBaseStd.cpp +++ b/tools/lldb-mi/MIUtilThreadBaseStd.cpp @@ -1,9 +1,8 @@ //===-- MIUtilThreadBaseStd.cpp ---------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -15,7 +14,6 @@ #include "MIUtilThreadBaseStd.h" //++ -//------------------------------------------------------------------------------------ // Details: Constructor. // Type: None. // Args: None. @@ -26,7 +24,6 @@ CMIUtilThreadActiveObjBase::CMIUtilThreadActiveObjBase() : m_references(0), m_bHasBeenKilled(false) {} //++ -//------------------------------------------------------------------------------------ // Details: Destructor. // Type: None. // Args: None. @@ -39,7 +36,6 @@ CMIUtilThreadActiveObjBase::~CMIUtilThreadActiveObjBase() { } //++ -//------------------------------------------------------------------------------------ // Details: Check if an object is already running. // Type: Method. // Args: None. @@ -53,7 +49,6 @@ bool CMIUtilThreadActiveObjBase::ThreadIsActive() { } //++ -//------------------------------------------------------------------------------------ // Details: Set up *this thread. // Type: Method. // Args: None. @@ -67,7 +62,6 @@ bool CMIUtilThreadActiveObjBase::ThreadExecute() { } //++ -//------------------------------------------------------------------------------------ // Details: Acquire a reference to CMIUtilThreadActiveObjBase. // Type: Method. // Args: None. @@ -86,7 +80,6 @@ bool CMIUtilThreadActiveObjBase::Acquire() { } //++ -//------------------------------------------------------------------------------------ // Details: Release a reference to CMIUtilThreadActiveObjBase. // Type: Method. // Args: None. @@ -105,7 +98,6 @@ bool CMIUtilThreadActiveObjBase::Release() { } //++ -//------------------------------------------------------------------------------------ // Details: Force this thread to stop, regardless of references // Type: Method. // Args: None. @@ -124,7 +116,6 @@ bool CMIUtilThreadActiveObjBase::ThreadKill() { } //++ -//------------------------------------------------------------------------------------ // Details: Proxy to thread join. // Type: Method. // Args: None. @@ -135,7 +126,6 @@ bool CMIUtilThreadActiveObjBase::ThreadKill() { bool CMIUtilThreadActiveObjBase::ThreadJoin() { return m_thread.Join(); } //++ -//------------------------------------------------------------------------------------ // Details: This function is the entry point of this object thread. // It is a trampoline to an instances operation manager. // Type: Static method. @@ -159,7 +149,6 @@ MIuint CMIUtilThreadActiveObjBase::ThreadEntry(void *vpThisClass) { } //++ -//------------------------------------------------------------------------------------ // Details: This function forms a small management routine, to handle the // thread's running. // Type: Method. @@ -197,15 +186,11 @@ void CMIUtilThreadActiveObjBase::ThreadManage() { m_thread.Finish(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- // CMIUtilThread::CMIUtilThread() : m_pThread(nullptr), m_bIsActive(false) {} //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilThread destructor. // Type: Method. // Args: None. @@ -215,7 +200,6 @@ CMIUtilThread::CMIUtilThread() : m_pThread(nullptr), m_bIsActive(false) {} CMIUtilThread::~CMIUtilThread() { Join(); } //++ -//------------------------------------------------------------------------------------ // Details: Wait for thread to stop. // Type: Method. // Args: None. @@ -240,7 +224,6 @@ bool CMIUtilThread::Join() { } //++ -//------------------------------------------------------------------------------------ // Details: Is the thread doing work. // Type: Method. // Args: None. @@ -254,7 +237,6 @@ bool CMIUtilThread::IsActive() { } //++ -//------------------------------------------------------------------------------------ // Details: Finish this thread // Type: Method. // Args: None. @@ -268,7 +250,6 @@ void CMIUtilThread::Finish() { } //++ -//------------------------------------------------------------------------------------ // Details: Set up *this thread. // Type: Method. // Args: vpFn (R) - Function pointer to thread's main function. @@ -291,12 +272,8 @@ bool CMIUtilThread::Start(FnThreadProc vpFn, void *vpArg) { return MIstatus::success; } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: Take resource. // Type: Method. // Args: None. @@ -306,7 +283,6 @@ bool CMIUtilThread::Start(FnThreadProc vpFn, void *vpArg) { void CMIUtilThreadMutex::Lock() { m_mutex.lock(); } //++ -//------------------------------------------------------------------------------------ // Details: Release resource. // Type: Method. // Args: None. @@ -316,7 +292,6 @@ void CMIUtilThreadMutex::Lock() { m_mutex.lock(); } void CMIUtilThreadMutex::Unlock() { m_mutex.unlock(); } //++ -//------------------------------------------------------------------------------------ // Details: Take resource if available. Immediately return in either case. // Type: Method. // Args: None. diff --git a/tools/lldb-mi/MIUtilThreadBaseStd.h b/tools/lldb-mi/MIUtilThreadBaseStd.h index 20b8fad9947a..3fa03b6f072e 100644 --- a/tools/lldb-mi/MIUtilThreadBaseStd.h +++ b/tools/lldb-mi/MIUtilThreadBaseStd.h @@ -1,9 +1,8 @@ //===-- MIUtilThreadBaseStd.h -----------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// diff --git a/tools/lldb-mi/MIUtilVariant.cpp b/tools/lldb-mi/MIUtilVariant.cpp index c317e3e687f2..062dce80c4b9 100644 --- a/tools/lldb-mi/MIUtilVariant.cpp +++ b/tools/lldb-mi/MIUtilVariant.cpp @@ -1,9 +1,8 @@ //===-- MIUtilVariant.cpp----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -11,7 +10,6 @@ #include "MIUtilVariant.h" //++ -//------------------------------------------------------------------------------------ // Details: CDataObjectBase constructor. // Type: Method. // Args: None. @@ -21,7 +19,6 @@ CMIUtilVariant::CDataObjectBase::CDataObjectBase() {} //++ -//------------------------------------------------------------------------------------ // Details: CDataObjectBase copy constructor. // Type: Method. // Args: vrOther - (R) The other object. @@ -34,7 +31,6 @@ CMIUtilVariant::CDataObjectBase::CDataObjectBase( } //++ -//------------------------------------------------------------------------------------ // Details: CDataObjectBase copy constructor. // Type: Method. // Args: vrOther - (R) The other object. @@ -46,7 +42,6 @@ CMIUtilVariant::CDataObjectBase::CDataObjectBase(CDataObjectBase &vrOther) { } //++ -//------------------------------------------------------------------------------------ // Details: CDataObjectBase move constructor. // Type: Method. // Args: vrwOther - (R) The other object. @@ -58,7 +53,6 @@ CMIUtilVariant::CDataObjectBase::CDataObjectBase(CDataObjectBase &&vrwOther) { } //++ -//------------------------------------------------------------------------------------ // Details: CDataObjectBase destructor. // Type: Overrideable. // Args: None. @@ -68,7 +62,6 @@ CMIUtilVariant::CDataObjectBase::CDataObjectBase(CDataObjectBase &&vrwOther) { CMIUtilVariant::CDataObjectBase::~CDataObjectBase() { Destroy(); } //++ -//------------------------------------------------------------------------------------ // Details: CDataObjectBase copy assignment. // Type: Method. // Args: vrOther - (R) The other object. @@ -82,7 +75,6 @@ operator=(const CDataObjectBase &vrOther) { } //++ -//------------------------------------------------------------------------------------ // Details: CDataObjectBase move assignment. // Type: Method. // Args: vrwOther - (R) The other object. @@ -97,7 +89,6 @@ operator=(CDataObjectBase &&vrwOther) { } //++ -//------------------------------------------------------------------------------------ // Details: Create a new copy of *this class. // Type: Overrideable. // Args: None. @@ -111,7 +102,6 @@ CMIUtilVariant::CDataObjectBase::CreateCopyOfSelf() { } //++ -//------------------------------------------------------------------------------------ // Details: Determine if *this object is a derived from CDataObjectBase. // Type: Overrideable. // Args: None. @@ -125,7 +115,6 @@ bool CMIUtilVariant::CDataObjectBase::GetIsDerivedClass() const { } //++ -//------------------------------------------------------------------------------------ // Details: Perform a bitwise copy of *this object. // Type: Overrideable. // Args: vrOther - (R) The other object. @@ -138,7 +127,6 @@ void CMIUtilVariant::CDataObjectBase::Copy(const CDataObjectBase &vrOther) { } //++ -//------------------------------------------------------------------------------------ // Details: Release any resources used by *this object. // Type: Overrideable. // Args: None. @@ -149,12 +137,8 @@ void CMIUtilVariant::CDataObjectBase::Destroy() { // Do nothing - override to implement } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CDataObject copy constructor. // Type: Method. // Args: T - The object's type. @@ -170,7 +154,6 @@ CMIUtilVariant::CDataObject<T>::CDataObject(const CDataObject &vrOther) { } //++ -//------------------------------------------------------------------------------------ // Details: CDataObject copy constructor. // Type: Method. // Args: T - The object's type. @@ -186,7 +169,6 @@ CMIUtilVariant::CDataObject<T>::CDataObject(CDataObject &vrOther) { } //++ -//------------------------------------------------------------------------------------ // Details: CDataObject move constructor. // Type: Method. // Args: T - The object's type. @@ -203,7 +185,6 @@ CMIUtilVariant::CDataObject<T>::CDataObject(CDataObject &&vrwOther) { } //++ -//------------------------------------------------------------------------------------ // Details: CDataObject copy assignment. // Type: Method. // Args: T - The object's type. @@ -221,7 +202,6 @@ operator=(const CDataObject &vrOther) { } //++ -//------------------------------------------------------------------------------------ // Details: CDataObject move assignment. // Type: Method. // Args: T - The object's type. @@ -239,12 +219,8 @@ operator=(CDataObject &&vrwOther) { return *this; } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilVariant constructor. // Type: Method. // Args: None. @@ -254,7 +230,6 @@ operator=(CDataObject &&vrwOther) { CMIUtilVariant::CMIUtilVariant() : m_pDataObject(nullptr) {} //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilVariant copy constructor. // Type: Method. // Args: vrOther - (R) The other object. @@ -270,7 +245,6 @@ CMIUtilVariant::CMIUtilVariant(const CMIUtilVariant &vrOther) } //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilVariant copy constructor. // Type: Method. // Args: vrOther - (R) The other object. @@ -286,7 +260,6 @@ CMIUtilVariant::CMIUtilVariant(CMIUtilVariant &vrOther) } //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilVariant move constructor. // Type: Method. // Args: vrwOther - (R) The other object. @@ -303,7 +276,6 @@ CMIUtilVariant::CMIUtilVariant(CMIUtilVariant &&vrwOther) } //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilVariant destructor. // Type: Method. // Args: None. @@ -313,7 +285,6 @@ CMIUtilVariant::CMIUtilVariant(CMIUtilVariant &&vrwOther) CMIUtilVariant::~CMIUtilVariant() { Destroy(); } //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilVariant copy assignment. // Type: Method. // Args: vrOther - (R) The other object. @@ -329,7 +300,6 @@ CMIUtilVariant &CMIUtilVariant::operator=(const CMIUtilVariant &vrOther) { } //++ -//------------------------------------------------------------------------------------ // Details: CMIUtilVariant move assignment. // Type: Method. // Args: vrwOther - (R) The other object. @@ -346,7 +316,6 @@ CMIUtilVariant &CMIUtilVariant::operator=(CMIUtilVariant &&vrwOther) { } //++ -//------------------------------------------------------------------------------------ // Details: Release the resources used by *this object. // Type: Method. // Args: None. @@ -360,7 +329,6 @@ void CMIUtilVariant::Destroy() { } //++ -//------------------------------------------------------------------------------------ // Details: Bitwise copy another data object to *this variant object. // Type: Method. // Args: vrOther - (R) The other object. diff --git a/tools/lldb-mi/MIUtilVariant.h b/tools/lldb-mi/MIUtilVariant.h index 01dd615aad67..4c9db33021b5 100644 --- a/tools/lldb-mi/MIUtilVariant.h +++ b/tools/lldb-mi/MIUtilVariant.h @@ -1,9 +1,8 @@ //===-- MIUtilVariant.h -----------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// @@ -117,12 +116,8 @@ private: CDataObjectBase *m_pDataObject; }; -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: CDataObject constructor. // Type: Method. // Args: T - The object's type. @@ -132,7 +127,6 @@ private: template <typename T> CMIUtilVariant::CDataObject<T>::CDataObject() {} //++ -//------------------------------------------------------------------------------------ // Details: CDataObject constructor. // Type: Method. // Args: T - The object's type. @@ -146,7 +140,6 @@ CMIUtilVariant::CDataObject<T>::CDataObject(const T &vArg) { } //++ -//------------------------------------------------------------------------------------ // Details: CDataObject destructor. // Type: Overridden. // Args: T - The object's type. @@ -158,7 +151,6 @@ template <typename T> CMIUtilVariant::CDataObject<T>::~CDataObject() { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the data object hold by *this object wrapper. // Type: Method. // Args: T - The object's type. @@ -170,7 +162,6 @@ template <typename T> T &CMIUtilVariant::CDataObject<T>::GetDataObject() { } //++ -//------------------------------------------------------------------------------------ // Details: Create a new copy of *this class. // Type: Overridden. // Args: T - The object's type. @@ -186,7 +177,6 @@ CMIUtilVariant::CDataObject<T>::CreateCopyOfSelf() { } //++ -//------------------------------------------------------------------------------------ // Details: Determine if *this object is a derived from CDataObjectBase. // Type: Overridden. // Args: T - The object's type. @@ -200,7 +190,6 @@ bool CMIUtilVariant::CDataObject<T>::GetIsDerivedClass() const { } //++ -//------------------------------------------------------------------------------------ // Details: Perform a bitwise copy of *this object. // Type: Overrideable. // Args: T - The object's type. @@ -215,7 +204,6 @@ void CMIUtilVariant::CDataObject<T>::Duplicate(const CDataObject &vrOther) { } //++ -//------------------------------------------------------------------------------------ // Details: Release any resources used by *this object. // Type: Overridden. // Args: None. @@ -226,12 +214,8 @@ template <typename T> void CMIUtilVariant::CDataObject<T>::Destroy() { CDataObjectBase::Destroy(); } -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- -//--------------------------------------------------------------------------------------- //++ -//------------------------------------------------------------------------------------ // Details: Assign to the variant an object of a specified type. // Type: Template method. // Args: T - The object's type. @@ -244,7 +228,6 @@ template <typename T> void CMIUtilVariant::Set(const T &vArg) { } //++ -//------------------------------------------------------------------------------------ // Details: Retrieve the data object from *this variant. // Type: Template method. // Args: T - The object's type. diff --git a/tools/lldb-mi/Platform.h b/tools/lldb-mi/Platform.h index ce2de1b6e97d..aa999f51b956 100644 --- a/tools/lldb-mi/Platform.h +++ b/tools/lldb-mi/Platform.h @@ -1,9 +1,8 @@ //===-- Platform.h ----------------------------------------------*- C++ -*-===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// 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 // //===----------------------------------------------------------------------===// #pragma once |