| 3083 | } |
| 3084 | |
| 3085 | void BfAutoComplete::CheckVarResolution(BfAstNode* varTypeRef, BfType* resolvedType) |
| 3086 | { |
| 3087 | if (IsAutocompleteNode(varTypeRef)) |
| 3088 | { |
| 3089 | if ((resolvedType == NULL) || (resolvedType->IsVar()) || (resolvedType->IsLet())) |
| 3090 | return; |
| 3091 | |
| 3092 | if (mIsGetDefinition) |
| 3093 | { |
| 3094 | auto typeInst = resolvedType->ToTypeInstance(); |
| 3095 | if (typeInst != NULL) |
| 3096 | { |
| 3097 | if (typeInst->mTypeDef->mTypeDeclaration != NULL) |
| 3098 | SetDefinitionLocation(typeInst->mTypeDef->mTypeDeclaration->mNameNode); |
| 3099 | } |
| 3100 | } |
| 3101 | |
| 3102 | if (mResolveType == BfResolveType_GetResultString) |
| 3103 | { |
| 3104 | mResultString = ":"; |
| 3105 | mResultString += mModule->TypeToString(resolvedType, (BfTypeNameFlags)(BfTypeNameFlag_ExtendedInfo | BfTypeNameFlag_ResolveGenericParamNames)); |
| 3106 | } |
| 3107 | } |
| 3108 | } |
| 3109 | |
| 3110 | class BfAutocompleteNodeChecker : public BfStructuralVisitor |
| 3111 | { |
no test coverage detected