|
|
|
@ -42,11 +42,11 @@ std::vector<clang::Cursor> clang::Tokens::get_token_cursors(clang::TranslationUn |
|
|
|
auto type=clang_getCursorType(referenced); |
|
|
|
auto type=clang_getCursorType(referenced); |
|
|
|
std::string spelling=clang_getCString(clang_getTypeSpelling(type)); |
|
|
|
std::string spelling=clang_getCString(clang_getTypeSpelling(type)); |
|
|
|
std::string auto_end=""; |
|
|
|
std::string auto_end=""; |
|
|
|
if(spelling.substr(0, 4)=="auto") { |
|
|
|
if(spelling.size()>=4 && spelling.substr(0, 4)=="auto") { |
|
|
|
auto_end=spelling.substr(4); |
|
|
|
auto_end=spelling.substr(4); |
|
|
|
auto type=clang_getCanonicalType(clang_getCursorType(cursors[c].cursor_)); |
|
|
|
auto type=clang_getCanonicalType(clang_getCursorType(cursors[c].cursor_)); |
|
|
|
spelling=clang_getCString(clang_getTypeSpelling(type)); |
|
|
|
spelling=clang_getCString(clang_getTypeSpelling(type)); |
|
|
|
if(spelling.substr(0, 4)!="auto" && spelling.substr(4)!=auto_end) |
|
|
|
if(spelling.size()>=4 && spelling.substr(0, 4)!="auto" && spelling.substr(4)!=auto_end) |
|
|
|
spelling+=auto_end; |
|
|
|
spelling+=auto_end; |
|
|
|
} |
|
|
|
} |
|
|
|
tks[c].type=spelling; |
|
|
|
tks[c].type=spelling; |
|
|
|
|