fix(compiler): Generate temporary variables for guarded expressions (#10657)

Fixes: #10639
This commit is contained in:
Chuck Jazdzewski
2016-08-11 21:20:54 -07:00
committed by vikerman
parent 5d59c6e80f
commit 2d520ae7e7
4 changed files with 176 additions and 24 deletions

View File

@ -59,7 +59,8 @@ export class CompileEventListener {
this._method.resetDebugInfo(this.compileElement.nodeIndex, hostEvent);
var context = isPresent(directiveInstance) ? directiveInstance :
this.compileElement.view.componentContext;
var actionStmts = convertCdStatementToIr(this.compileElement.view, context, hostEvent.handler);
var actionStmts = convertCdStatementToIr(
this.compileElement.view, context, hostEvent.handler, this.compileElement.nodeIndex);
var lastIndex = actionStmts.length - 1;
if (lastIndex >= 0) {
var lastStatement = actionStmts[lastIndex];