diff options
| author | Cyndy Ishida <cyndy_ishida@apple.com> | 2023-07-25 08:32:28 -0700 |
|---|---|---|
| committer | Cyndy Ishida <cyndy_ishida@apple.com> | 2023-07-25 09:23:57 -0700 |
| commit | 16c1f43642e40dbc0d59fcf68ed1682dbf4d87bd (patch) | |
| tree | 4e08556552e9ef8ac00af498ebdb24399e67d1ae /llvm/lib/TextAPI/TextAPIError.cpp | |
| parent | 0478ef2d366c6f88678e37d54190dcdaa0ec69da (diff) | |
[TextAPI] Add functionality to manipulate over InterfaceFiles
InterfaceFile is the in-memory representation for tbd files. Add APIs to
merge, extract, remove, and inline reexported libraries.
Reviewed By: zixuw
Differential Revision: https://reviews.llvm.org/D153398
Diffstat (limited to 'llvm/lib/TextAPI/TextAPIError.cpp')
| -rw-r--r-- | llvm/lib/TextAPI/TextAPIError.cpp | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/llvm/lib/TextAPI/TextAPIError.cpp b/llvm/lib/TextAPI/TextAPIError.cpp new file mode 100644 index 000000000000..07eae7ab4100 --- /dev/null +++ b/llvm/lib/TextAPI/TextAPIError.cpp @@ -0,0 +1,33 @@ +//===- TextAPIError.cpp - Tapi Error ----------------------------*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception +// +//===----------------------------------------------------------------------===// +/// +/// \file +/// \brief Implements TAPI Error. +/// +//===----------------------------------------------------------------------===// + +#include "llvm/TextAPI/TextAPIError.h" + +using namespace llvm; +using namespace llvm::MachO; + +char TextAPIError::ID = 0; + +void TextAPIError::log(raw_ostream &OS) const { + switch (EC) { + case TextAPIErrorCode::NoSuchArchitecture: + OS << "no such architecture\n"; + return; + default: + llvm_unreachable("unhandled TextAPIErrorCode"); + } +} + +std::error_code TextAPIError::convertToErrorCode() const { + llvm_unreachable("convertToErrorCode is not supported."); +} |
