diff --git a/lib/analyze-scope.js b/lib/analyze-scope.js index 9b2a40d6..f3dd11d5 100644 --- a/lib/analyze-scope.js +++ b/lib/analyze-scope.js @@ -18,6 +18,7 @@ const flowFlippedAliasKeys = t.FLIPPED_ALIAS_KEYS.Flow.concat([ "ObjectPattern", "RestElement", ]); + const visitorKeysMap = Object.keys(t.VISITOR_KEYS).reduce(function(acc, key) { const value = t.VISITOR_KEYS[key]; if (flowFlippedAliasKeys.indexOf(value) === -1) { @@ -131,6 +132,11 @@ class Referencer extends OriginalReferencer { super.visitProperty(node); } + CallExpression(node) { + this._visitTypeAnnotation(node.typeArguments); + super.CallExpression(node); + } + InterfaceDeclaration(node) { this._createScopeVariable(node, node.id);