[analyzer] Avoid out-of-order node traversal on void return (#117863)
[llvm-project.git] / lld / MachO / ObjC.h
blobdb259a82fbbdbb74ab03835f92f7a26631209de2
1 //===- ObjC.h ---------------------------------------------------*- C++ -*-===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
9 #ifndef LLD_MACHO_OBJC_H
10 #define LLD_MACHO_OBJC_H
12 #include "llvm/Support/MemoryBuffer.h"
14 namespace lld::macho {
16 namespace objc {
18 namespace symbol_names {
19 constexpr const char klass[] = "_OBJC_CLASS_$_";
20 constexpr const char klassPropList[] = "__OBJC_$_CLASS_PROP_LIST_";
22 constexpr const char metaclass[] = "_OBJC_METACLASS_$_";
23 constexpr const char ehtype[] = "_OBJC_EHTYPE_$_";
24 constexpr const char ivar[] = "_OBJC_IVAR_$_";
25 constexpr const char instanceMethods[] = "__OBJC_$_INSTANCE_METHODS_";
26 constexpr const char classMethods[] = "__OBJC_$_CLASS_METHODS_";
27 constexpr const char listProprieties[] = "__OBJC_$_PROP_LIST_";
29 constexpr const char category[] = "__OBJC_$_CATEGORY_";
30 constexpr const char categoryInstanceMethods[] =
31 "__OBJC_$_CATEGORY_INSTANCE_METHODS_";
32 constexpr const char categoryClassMethods[] =
33 "__OBJC_$_CATEGORY_CLASS_METHODS_";
34 constexpr const char categoryProtocols[] = "__OBJC_CATEGORY_PROTOCOLS_$_";
36 constexpr const char swift_objc_category[] = "__CATEGORY_";
37 constexpr const char swift_objc_klass[] = "_$s";
38 } // namespace symbol_names
40 // Check for duplicate method names within related categories / classes.
41 void checkCategories();
42 void mergeCategories();
44 void doCleanup();
45 } // namespace objc
47 bool hasObjCSection(llvm::MemoryBufferRef);
49 } // namespace lld::macho
51 #endif