Support iterators in spread element
This commit is contained in:
parent
b7f2990305
commit
2288946afc
|
@ -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)) {
|
||||
|
|
Loading…
Reference in a new issue