enum CXCursorKind ParentKind;
CXString ParentName;
CXString BriefComment;
+ CXString Annotation;
const char *BriefCommentCString;
fprintf(file, "%s:", clang_getCString(ks));
for (i = 0; i < annotationCount; ++i) {
if (i != 0)
fprintf(file, ", ");
- fprintf(file, "\"%s\"",
- clang_getCString(clang_getCompletionAnnotation(
- completion_result->CompletionString, i)));
+ Annotation =
+ clang_getCompletionAnnotation(completion_result->CompletionString, i);
+ fprintf(file, "\"%s\"", clang_getCString(Annotation));
+ clang_disposeString(Annotation);
}
fprintf(file, ")");
}