2014-07-13 01:04:16 +02:00
|
|
|
//// [importedModuleAddToGlobal.ts]
|
|
|
|
// Binding for an import statement in a typeref position is being added to the global scope
|
|
|
|
// Shouldn't compile b.B is not defined in C
|
|
|
|
module A {
|
|
|
|
import b = B;
|
|
|
|
import c = C;
|
|
|
|
}
|
|
|
|
|
|
|
|
module B {
|
|
|
|
import a = A;
|
|
|
|
export class B { }
|
|
|
|
}
|
|
|
|
|
|
|
|
module C {
|
|
|
|
import a = A;
|
|
|
|
function hello(): b.B { return null; }
|
|
|
|
}
|
|
|
|
|
|
|
|
//// [importedModuleAddToGlobal.js]
|
|
|
|
var B;
|
2015-03-24 00:16:29 +01:00
|
|
|
(function (B_1) {
|
2014-07-13 01:04:16 +02:00
|
|
|
var B = (function () {
|
|
|
|
function B() {
|
|
|
|
}
|
|
|
|
return B;
|
|
|
|
})();
|
2015-03-24 00:16:29 +01:00
|
|
|
B_1.B = B;
|
2014-07-13 01:04:16 +02:00
|
|
|
})(B || (B = {}));
|
|
|
|
var C;
|
|
|
|
(function (C) {
|
2015-03-26 21:46:35 +01:00
|
|
|
function hello() { return null; }
|
2014-07-13 01:04:16 +02:00
|
|
|
})(C || (C = {}));
|