mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-11-18 20:11:14 +00:00
Add null check when querying for exports from a module
This commit is contained in:
1 parent
c53b0a5016
commit
3ca76ca53b
7 files changed
+241
-1
No files matched your search
@@ -929,7 +929,7 @@ module ts {
|
||||
// The ES6 spec permits export * declarations in a module to circularly reference the module itself. For example,
|
||||
// module 'a' can 'export * from "b"' and 'b' can 'export * from "a"' without error.
|
||||
function visit(symbol: Symbol) {
|
||||
if (symbol.flags & SymbolFlags.HasExports && !contains(visitedSymbols, symbol)) {
|
||||
if (symbol && symbol.flags & SymbolFlags.HasExports && !contains(visitedSymbols, symbol)) {
|
||||
visitedSymbols.push(symbol);
|
||||
if (symbol !== moduleSymbol) {
|
||||
if (!result) {
|
||||
|
||||
Reference in new issue
Block a user