Update type checking for lexical binding due to merge with master

This commit is contained in:
Yui T 2015-01-23 17:08:08 -08:00
parent 581beb58dc
commit de9547cc9e

View file

@ -4832,9 +4832,12 @@ module ts {
container = getThisContainer(container, /* includeArrowFunctions */ false); container = getThisContainer(container, /* includeArrowFunctions */ false);
// When targeting es6, arrow function lexically bind "this" so we do not need to do the work of binding "this" in emitted code // When targeting es6, arrow function lexically bind "this" so we do not need to do the work of binding "this" in emitted code
if (compilerOptions.target < ScriptTarget.ES6) { if (compilerOptions.target >= ScriptTarget.ES6) {
needToCaptureLexicalThis = true; needToCaptureLexicalThis = false;
} }
else {
needToCaptureLexicalThis = true;
}
} }
switch (container.kind) { switch (container.kind) {