]> granicus.if.org Git - clang/commitdiff
[cindex.py] Add CachedProperty to CompletionChunk
authorTobias Grosser <grosser@fim.uni-passau.de>
Sun, 19 Aug 2012 22:26:15 +0000 (22:26 +0000)
committerTobias Grosser <grosser@fim.uni-passau.de>
Sun, 19 Aug 2012 22:26:15 +0000 (22:26 +0000)
Suggested by:  Francisco Lopes  <oblita@gmail.com>

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@162191 91177308-0d34-0410-b5e6-96231b3b80d8

bindings/python/clang/cindex.py

index d571b2ade934f82b4191911a84ff5d50534954dc..0605c2416fd6dcd8db9a060c7e8c8ef60817ff6c 100644 (file)
@@ -1657,16 +1657,16 @@ class CompletionChunk:
     def __repr__(self):
         return "{'" + self.spelling + "', " + str(self.kind) + "}"
 
-    @property
+    @CachedProperty
     def spelling(self):
         return lib.clang_getCompletionChunkText(self.cs, self.key).spelling
 
-    @property
+    @CachedProperty
     def kind(self):
         res = lib.clang_getCompletionChunkKind(self.cs, self.key)
         return completionChunkKindMap[res]
 
-    @property
+    @CachedProperty
     def string(self):
         res = lib.clang_getCompletionChunkCompletionString(self.cs, self.key)