summaryrefslogtreecommitdiffstats
path: root/lib/StaticAnalyzer/Core/CommonBugCategories.cpp
diff options
context:
space:
mode:
authorJordan Rose <jordan_rose@apple.com>2013-10-04 00:25:24 +0000
committerJordan Rose <jordan_rose@apple.com>2013-10-04 00:25:24 +0000
commitedcc199f5861dd8ad1ec3ad1b83512d2a92e515a (patch)
tree654557b6736937eab0db3acd74bf206d5645d982 /lib/StaticAnalyzer/Core/CommonBugCategories.cpp
parent10a61586e12fcd94dad877cbcf09cc34aec980d8 (diff)
[analyzer] Replace bug category magic strings with shared constants, take 2.
Re-commit r191910 (reverted in r191936) with layering violation fixed, by moving the bug categories to StaticAnalyzerCore instead of ...Checkers. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@191937 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/StaticAnalyzer/Core/CommonBugCategories.cpp')
-rw-r--r--lib/StaticAnalyzer/Core/CommonBugCategories.cpp20
1 files changed, 20 insertions, 0 deletions
diff --git a/lib/StaticAnalyzer/Core/CommonBugCategories.cpp b/lib/StaticAnalyzer/Core/CommonBugCategories.cpp
new file mode 100644
index 0000000000..3cb9323563
--- /dev/null
+++ b/lib/StaticAnalyzer/Core/CommonBugCategories.cpp
@@ -0,0 +1,20 @@
+//=--- CommonBugCategories.cpp - Provides common issue categories -*- C++ -*-=//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+
+#include "clang/StaticAnalyzer/Core/BugReporter/CommonBugCategories.h"
+
+// Common strings used for the "category" of many static analyzer issues.
+namespace clang { namespace ento { namespace categories {
+
+const char * const CoreFoundationObjectiveC = "Core Foundation/Objective-C";
+const char * const LogicError = "Logic error";
+const char * const MemoryCoreFoundationObjectiveC =
+ "Memory (Core Foundation/Objective-C)";
+const char * const UnixAPI = "Unix API";
+}}}