@@ -1275,10 +1275,9 @@ namespace ts.Completions {
1275
1275
getTypeScriptMemberSymbols ( ) ;
1276
1276
}
1277
1277
else if ( isRightOfOpenTag ) {
1278
- const tagSymbols = typeChecker . getJsxIntrinsicTagNamesAt ( location ) ;
1279
- Debug . assertEachIsDefined ( tagSymbols , "getJsxIntrinsicTagNames() should all be defined" ) ;
1278
+ symbols = typeChecker . getJsxIntrinsicTagNamesAt ( location ) ;
1279
+ Debug . assertEachIsDefined ( symbols , "getJsxIntrinsicTagNames() should all be defined" ) ;
1280
1280
tryGetGlobalSymbols ( ) ;
1281
- symbols = tagSymbols . concat ( symbols ) ;
1282
1281
completionKind = CompletionKind . Global ;
1283
1282
keywordFilters = KeywordCompletionFilters . None ;
1284
1283
}
@@ -1564,7 +1563,7 @@ namespace ts.Completions {
1564
1563
const attrsType = jsxContainer && typeChecker . getContextualType ( jsxContainer . attributes ) ;
1565
1564
if ( ! attrsType ) return GlobalsSearch . Continue ;
1566
1565
const completionsType = jsxContainer && typeChecker . getContextualType ( jsxContainer . attributes , ContextFlags . Completions ) ;
1567
- symbols = filterJsxAttributes ( getPropertiesForObjectExpression ( attrsType , completionsType , jsxContainer ! . attributes , typeChecker ) , jsxContainer ! . attributes . properties ) ;
1566
+ symbols = concatenate ( symbols , filterJsxAttributes ( getPropertiesForObjectExpression ( attrsType , completionsType , jsxContainer ! . attributes , typeChecker ) , jsxContainer ! . attributes . properties ) ) ;
1568
1567
setSortTextToOptionalMember ( ) ;
1569
1568
completionKind = CompletionKind . MemberLike ;
1570
1569
isNewIdentifierLocation = false ;
@@ -1621,7 +1620,7 @@ namespace ts.Completions {
1621
1620
1622
1621
const symbolMeanings = ( isTypeOnly ? SymbolFlags . None : SymbolFlags . Value ) | SymbolFlags . Type | SymbolFlags . Namespace | SymbolFlags . Alias ;
1623
1622
1624
- symbols = typeChecker . getSymbolsInScope ( scopeNode , symbolMeanings ) ;
1623
+ symbols = concatenate ( symbols , typeChecker . getSymbolsInScope ( scopeNode , symbolMeanings ) ) ;
1625
1624
Debug . assertEachIsDefined ( symbols , "getSymbolsInScope() should all be defined" ) ;
1626
1625
for ( const symbol of symbols ) {
1627
1626
if ( ! typeChecker . isArgumentsSymbol ( symbol ) &&
@@ -1957,7 +1956,7 @@ namespace ts.Completions {
1957
1956
const existingMemberEscapedNames : Set < __String > = new Set ( ) ;
1958
1957
existingMembers . forEach ( s => existingMemberEscapedNames . add ( s . escapedName ) ) ;
1959
1958
1960
- symbols = filter ( members , s => ! existingMemberEscapedNames . has ( s . escapedName ) ) ;
1959
+ symbols = concatenate ( symbols , filter ( members , s => ! existingMemberEscapedNames . has ( s . escapedName ) ) ) ;
1961
1960
1962
1961
completionKind = CompletionKind . ObjectPropertyDeclaration ;
1963
1962
isNewIdentifierLocation = true ;
@@ -2046,7 +2045,7 @@ namespace ts.Completions {
2046
2045
2047
2046
if ( typeMembers && typeMembers . length > 0 ) {
2048
2047
// Add filtered items to the completion list
2049
- symbols = filterObjectMembersList ( typeMembers , Debug . checkDefined ( existingMembers ) ) ;
2048
+ symbols = concatenate ( symbols , filterObjectMembersList ( typeMembers , Debug . checkDefined ( existingMembers ) ) ) ;
2050
2049
}
2051
2050
setSortTextToOptionalMember ( ) ;
2052
2051
@@ -2082,7 +2081,7 @@ namespace ts.Completions {
2082
2081
isNewIdentifierLocation = false ;
2083
2082
const exports = typeChecker . getExportsAndPropertiesOfModule ( moduleSpecifierSymbol ) ;
2084
2083
const existing = new Set ( ( namedImportsOrExports . elements as NodeArray < ImportOrExportSpecifier > ) . filter ( n => ! isCurrentlyEditingNode ( n ) ) . map ( n => ( n . propertyName || n . name ) . escapedText ) ) ;
2085
- symbols = exports . filter ( e => e . escapedName !== InternalSymbolName . Default && ! existing . has ( e . escapedName ) ) ;
2084
+ symbols = concatenate ( symbols , exports . filter ( e => e . escapedName !== InternalSymbolName . Default && ! existing . has ( e . escapedName ) ) ) ;
2086
2085
return GlobalsSearch . Success ;
2087
2086
}
2088
2087
@@ -2161,7 +2160,7 @@ namespace ts.Completions {
2161
2160
type ?. symbol && typeChecker . getPropertiesOfType ( typeChecker . getTypeOfSymbolAtLocation ( type . symbol , decl ) ) :
2162
2161
type && typeChecker . getPropertiesOfType ( type ) ;
2163
2162
} ) ;
2164
- symbols = filterClassMembersList ( baseSymbols , decl . members , classElementModifierFlags ) ;
2163
+ symbols = concatenate ( symbols , filterClassMembersList ( baseSymbols , decl . members , classElementModifierFlags ) ) ;
2165
2164
}
2166
2165
2167
2166
return GlobalsSearch . Success ;
0 commit comments