[cfe-commits] r142289 - /cfe/trunk/tools/c-index-test/c-index-test.c
Argyrios Kyrtzidis
akyrtzi at gmail.com
Mon Oct 17 15:12:24 PDT 2011
Author: akirtzidis
Date: Mon Oct 17 17:12:24 2011
New Revision: 142289
URL: http://llvm.org/viewvc/llvm-project?rev=142289&view=rev
Log:
Try fixing MSVC compiler errors.
Modified:
cfe/trunk/tools/c-index-test/c-index-test.c
Modified: cfe/trunk/tools/c-index-test/c-index-test.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/tools/c-index-test/c-index-test.c?rev=142289&r1=142288&r2=142289&view=diff
==============================================================================
--- cfe/trunk/tools/c-index-test/c-index-test.c (original)
+++ cfe/trunk/tools/c-index-test/c-index-test.c Mon Oct 17 17:12:24 2011
@@ -1507,6 +1507,7 @@
const char *cname, *end;
CXIdxFile file;
unsigned line, column;
+ int isHeader;
clang_indexLoc_getFileLocation(loc, &file, 0, &line, &column, 0);
if (line == 0) {
@@ -1516,7 +1517,7 @@
filename = clang_getFileName((CXFile)file);
cname = clang_getCString(filename);
end = cname + strlen(cname);
- int isHeader = (end[-2] == '.' && end[-1] == 'h');
+ isHeader = (end[-2] == '.' && end[-1] == 'h');
if (isHeader) {
printCXIndexFile(file);
@@ -1685,9 +1686,14 @@
static CXIdxEntity index_importedEntity(CXClientData client_data,
CXIdxImportedEntityInfo *info) {
IndexData *index_data;
- CXIdxIndexedDeclInfo DeclInfo = { info->cursor, info->loc, 0 };
- CXIdxIndexedEntityInfo EntityInfo = { info->entityInfo, &DeclInfo };
+ CXIdxIndexedDeclInfo DeclInfo;
+ CXIdxIndexedEntityInfo EntityInfo;
const char *name;
+ DeclInfo.cursor = info->cursor;
+ DeclInfo.loc = info->loc;
+ DeclInfo.container = 0;
+ EntityInfo.entityInfo = info->entityInfo;
+ EntityInfo.declInfo = &DeclInfo;
index_data = (IndexData *)client_data;
printCheck(index_data);
More information about the cfe-commits
mailing list