make globalThis have an empty declarations (#34561)

Fixes #33860 by making it an error.  This is an improvement, but sounds
like it would be better to make it work later.
This commit is contained in:
Eli Barzilay
2019-10-25 22:49:31 -04:00
committed by GitHub
parent d8840f8a18
commit eb0208c589
8 changed files with 55 additions and 5 deletions

View File

@@ -319,6 +319,7 @@ namespace ts {
const globalThisSymbol = createSymbol(SymbolFlags.Module, "globalThis" as __String, CheckFlags.Readonly);
globalThisSymbol.exports = globals;
globalThisSymbol.declarations = [];
globals.set(globalThisSymbol.escapedName, globalThisSymbol);
const argumentsSymbol = createSymbol(SymbolFlags.Property, "arguments" as __String);