-
Notifications
You must be signed in to change notification settings - Fork 15
/
XcodeWarnings.xcconfig
159 lines (142 loc) · 5.55 KB
/
XcodeWarnings.xcconfig
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
// XcodeWarnings by Jon Reid, https://qualitycoding.org
// Copyright 2022 Jonathan M. Reid. See LICENSE.txt
// Source: https://github.com/jonreid/XcodeWarnings
// Apple Clang - Address Sanitizer
CLANG_ADDRESS_SANITIZER_CONTAINER_OVERFLOW = YES
// Apple Clang - Code Generation
GCC_STRICT_ALIASING = YES
GCC_REUSE_STRINGS = YES
GCC_NO_COMMON_BLOCKS = YES
GCC_THREADSAFE_STATICS = YES
// Apple Clang - Language
GCC_ENABLE_TRIGRAPHS = NO
// Apple Clang - Preprocessing
ENABLE_STRICT_OBJC_MSGSEND = YES
// Apple Clang - Undefined Behavior Sanitizer
CLANG_UNDEFINED_BEHAVIOR_SANITIZER_INTEGER = YES
CLANG_UNDEFINED_BEHAVIOR_SANITIZER_NULLABILITY = YES
// Apple Clang - Warning Policies
//GCC_WARN_PEDANTIC = YES
//GCC_TREAT_WARNINGS_AS_ERRORS = YES
//SWIFT_TREAT_WARNINGS_AS_ERRORS = YES
// Apple Clang - Warnings - All languages
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES
GCC_WARN_CHECK_SWITCH_STATEMENTS = YES
CLANG_WARN_COMPLETION_HANDLER_MISUSE = YES
GCC_WARN_ABOUT_DEPRECATED_FUNCTIONS = YES
CLANG_WARN_DOCUMENTATION_COMMENTS = YES
CLANG_WARN_EMPTY_BODY = YES
GCC_WARN_FOUR_CHARACTER_CONSTANTS = YES
GCC_WARN_SHADOW = YES
CLANG_WARN_BOOL_CONVERSION = YES
CLANG_WARN_CONSTANT_CONVERSION = YES
GCC_WARN_64_TO_32_BIT_CONVERSION = YES
CLANG_WARN_ENUM_CONVERSION = YES
CLANG_WARN_FLOAT_CONVERSION = YES
CLANG_WARN_INT_CONVERSION = YES
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES
CLANG_WARN_IMPLICIT_SIGN_CONVERSION = YES
CLANG_WARN_INFINITE_RECURSION = YES
GCC_WARN_INITIALIZER_NOT_FULLY_BRACKETED = YES
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR
GCC_WARN_MISSING_PARENTHESES = YES
GCC_WARN_ABOUT_MISSING_FIELD_INITIALIZERS = YES
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES
GCC_WARN_ABOUT_MISSING_NEWLINE = YES
CLANG_WARN_ASSIGN_ENUM = YES
CLANG_WARN_PRIVATE_MODULE = YES
GCC_WARN_ABOUT_POINTER_SIGNEDNESS = YES
CLANG_WARN_FRAMEWORK_INCLUDE_PRIVATE_FROM_PUBLIC = YES
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES
CLANG_WARN_SEMICOLON_BEFORE_METHOD_BODY = YES
GCC_WARN_SIGN_COMPARE = YES
CLANG_WARN_STRICT_PROTOTYPES = YES
CLANG_WARN_COMMA = YES
CLANG_WARN_SUSPICIOUS_IMPLICIT_CONVERSION = YES
CLANG_WARN_PRAGMA_PACK = YES
GCC_TREAT_INCOMPATIBLE_POINTER_TYPE_WARNINGS_AS_ERRORS = YES
GCC_TREAT_IMPLICIT_FUNCTION_DECLARATIONS_AS_ERRORS = YES
GCC_WARN_TYPECHECK_CALLS_TO_PRINTF = YES
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE
GCC_WARN_UNKNOWN_PRAGMAS = YES
CLANG_WARN_UNREACHABLE_CODE = YES_AGGRESSIVE
GCC_WARN_UNUSED_FUNCTION = YES
GCC_WARN_UNUSED_LABEL = YES
//GCC_WARN_UNUSED_PARAMETER = YES
GCC_WARN_UNUSED_VALUE = YES
GCC_WARN_UNUSED_VARIABLE = YES
// Apple Clang - Warnings - C++
CLANG_WARN_VEXING_PARSE = YES
CLANG_WARN_DELETE_NON_VIRTUAL_DTOR = YES
CLANG_WARN__EXIT_TIME_DESTRUCTORS = YES
GCC_WARN_NON_VIRTUAL_DESTRUCTOR = YES
GCC_WARN_HIDDEN_VIRTUAL_FUNCTIONS = YES
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES
CLANG_WARN_SUSPICIOUS_MOVE = YES
GCC_WARN_ABOUT_INVALID_OFFSETOF_MACRO = YES
CLANG_WARN_ATOMIC_IMPLICIT_SEQ_CST = YES
CLANG_WARN_CXX0X_EXTENSIONS = YES
// Apple Clang - Warnings - Objective-C
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES
CLANG_WARN_OBJC_IMPLICIT_ATOMIC_PROPERTIES = YES
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES
GCC_WARN_ALLOW_INCOMPLETE_PROTOCOL = YES
CLANG_WARN_OBJC_INTERFACE_IVARS = YES
CLANG_WARN_MISSING_NOESCAPE = YES
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES
GCC_WARN_STRICT_SELECTOR_MATCH = YES
GCC_WARN_UNDECLARED_SELECTOR = YES
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR
// Apple Clang - Warnings - Objective-C and ARC
CLANG_WARN_OBJC_EXPLICIT_OWNERSHIP_TYPE = YES
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES
CLANG_WARN_OBJC_REPEATED_USE_OF_WEAK = YES_AGGRESSIVE
CLANG_WARN__ARC_BRIDGE_CAST_NONARC = YES
// Static Analysis - Analysis Policy
RUN_CLANG_STATIC_ANALYZER = YES
CLANG_STATIC_ANALYZER_MODE_ON_ANALYZE_ACTION = Deep
CLANG_STATIC_ANALYZER_MODE = Deep
// Static Analysis - Generic Issues
CLANG_ANALYZER_NULL_DEREFERENCE = YES
CLANG_ANALYZER_DIVIDE_BY_ZERO = YES
CLANG_ANALYZER_MEMORY_MANAGEMENT = YES
CLANG_TIDY_BUGPRONE_INFINITE_LOOP = YES
CLANG_ANALYZER_NONNULL = YES_AGGRESSIVE
CLANG_TIDY_BUGPRONE_ASSERT_SIDE_EFFECT = YES
// Static Analysis - Issues - Apple APIs
CLANG_ANALYZER_OSOBJECT_C_STYLE_CAST = YES
CLANG_ANALYZER_OBJC_NSCFERROR = YES
CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES
CLANG_ANALYZER_LOCALIZABILITY_EMPTY_CONTEXT = YES
CLANG_ANALYZER_OBJC_COLLECTIONS = YES
CLANG_ANALYZER_GCD = YES
CLANG_ANALYZER_GCD_PERFORMANCE = YES
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE
CLANG_ANALYZER_LIBKERN_RETAIN_COUNT = YES
CLANG_ANALYZER_MIG_CONVENTIONS = YES
// Static Analysis - Issues - C++
CLANG_TIDY_BUGPRONE_MOVE_FORWARDING_REFERENCE = YES
CLANG_ANALYZER_USE_AFTER_MOVE = YES_AGGRESSIVE
// Static Analysis - Issues - Objective-C
CLANG_ANALYZER_OBJC_ATSYNC = YES
CLANG_ANALYZER_OBJC_DEALLOC = YES
CLANG_ANALYZER_OBJC_INCOMP_METHOD_TYPES = YES
CLANG_ANALYZER_OBJC_GENERICS = YES
CLANG_ANALYZER_OBJC_UNUSED_IVARS = YES
CLANG_ANALYZER_OBJC_SELF_INIT = YES
CLANG_ANALYZER_OBJC_RETAIN_COUNT = YES
// Static Analysis - Issues - Security
CLANG_ANALYZER_SECURITY_FLOATLOOPCOUNTER = YES
CLANG_ANALYZER_SECURITY_KEYCHAIN_API = YES
CLANG_ANALYZER_SECURITY_INSECUREAPI_UNCHECKEDRETURN = YES
CLANG_ANALYZER_SECURITY_INSECUREAPI_GETPW_GETS = YES
CLANG_ANALYZER_SECURITY_INSECUREAPI_MKSTEMP = YES
CLANG_ANALYZER_SECURITY_INSECUREAPI_RAND = YES
CLANG_ANALYZER_SECURITY_INSECUREAPI_STRCPY = YES
CLANG_ANALYZER_SECURITY_INSECUREAPI_VFORK = YES
// Static Analysis - Issues - Unused Code
CLANG_ANALYZER_DEADCODE_DEADSTORES = YES
CLANG_TIDY_MISC_REDUNDANT_EXPRESSION = YES
CLANG_TIDY_BUGPRONE_REDUNDANT_BRANCH_CONDITION = YES