mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-05-18 07:29:16 -05:00
Support iterators in spread element
This commit is contained in:
@@ -5913,7 +5913,7 @@ module ts {
|
||||
function checkSpreadElementExpression(node: SpreadElementExpression, contextualMapper?: TypeMapper): Type {
|
||||
let arrayOrIterableType = checkExpressionCached(node.expression, contextualMapper);
|
||||
if (languageVersion >= ScriptTarget.ES6) {
|
||||
// Check for iterable, not yet implemented
|
||||
return checkIteratedType(arrayOrIterableType, node.expression) || unknownType;
|
||||
}
|
||||
|
||||
if (isArrayLikeType(arrayOrIterableType)) {
|
||||
|
||||
Reference in New Issue
Block a user