Opened 13 years ago

Closed 13 years ago

#2340 closed defect (worksforme)

Compressor doesn't rename all occurrences of a variable

Reported by: guest Owned by: anonymous
Priority: high Milestone:
Component: General Version: 0.4.1
Keywords: Cc:
Blocked By: Blocking:

Description

In this javascript snippet:

function ponEstado(vis) {
	ico.setSource(vis ? 'widget/tree/minus.gif':'widget/tree/plus.gif');
	ctrl.setDisplay(vis);
	resumen.setHtml(vis ? '': param.queResumen(ctrl));
}
var resumen = new qx.ui.basic.Label;
.....
conTit.addEventListener('click', function() {
	ponEstado(!ctrl.getDisplay());
});

is compressed as:

function ponEstado(vis){
ico.setSource(vis?"widget/tree/minus.gif":"widget/tree/plus.gif");
_5f.setDisplay(vis);
resumen.setHtml(vis?"":_5e.queResumen(_5f));
}
var _62=new qx.ui.basic.Label;
....
_65.addEventListener("click",function(){
ponEstado(!_5f.getDisplay());
});

as you can see the variable called resumen isn't fully renamed. function ponEstado() is a closure we reuse later.

Change History (4)

comment:1 Changed 13 years ago by guest

This causes runtime errors, because resumen can't be referenced.

comment:2 Changed 13 years ago by craquerpro at yahoo dot es

I forgot to mention my email: craquerpro at yahoo dot es

comment:3 Changed 13 years ago by guest

Tried latest Dojo and is solved! :-)

comment:4 Changed 13 years ago by Adam Peller

Resolution: worksforme
Status: newclosed

Sounds like we can close this, then.

Note: See TracTickets for help on using tickets.