summaryrefslogtreecommitdiffstats
path: root/clang/bindings/python
diff options
context:
space:
mode:
Diffstat (limited to 'clang/bindings/python')
-rw-r--r--clang/bindings/python/clang/cindex.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/clang/bindings/python/clang/cindex.py b/clang/bindings/python/clang/cindex.py
index 5078825f147..eea7d331aef 100644
--- a/clang/bindings/python/clang/cindex.py
+++ b/clang/bindings/python/clang/cindex.py
@@ -361,13 +361,13 @@ class Diagnostic(object):
@property
def category_number(self):
- """The category number for this diagnostic."""
+ """The category number for this diagnostic or 0 if unavailable."""
return conf.lib.clang_getDiagnosticCategory(self)
@property
def category_name(self):
"""The string name of the category for this diagnostic."""
- return conf.lib.clang_getDiagnosticCategoryName(self.category_number)
+ return conf.lib.clang_getDiagnosticCategoryText(self)
@property
def option(self):
@@ -2922,8 +2922,8 @@ functionList = [
[Diagnostic],
c_uint),
- ("clang_getDiagnosticCategoryName",
- [c_uint],
+ ("clang_getDiagnosticCategoryText",
+ [Diagnostic],
_CXString,
_CXString.from_result),
OpenPOWER on IntegriCloud