-
Notifications
You must be signed in to change notification settings - Fork 54
Open
Description
If a comment is followed by a brace, the brace is moved to the end of the comment and is effectively commented out. Now the code won't compile because the brace is missing as it's now part of the comment. It happens anytime a brace is followed by a comment. This happens quite consistently in a large code base. When this happens extra braces are inserted.
as3 code for example:
if(labelRenderer !== null) //both label and icon
{
if(this._iconPosition !== RelativePosition.TOP &&
this._iconPosition !== RelativePosition.BOTTOM &&
this._iconPosition !== RelativePosition.MANUAL)
{
newWidth += adjustedGap + this.currentIcon.width;
}
else if(this.currentIcon.width > newWidth) //top, bottom, or manual
{
newWidth = this.currentIcon.width;
}
}
else //no label
{
newWidth = this.currentIcon.width;
}
This example should pass through unchanged but the actual result is:-
if (labelRenderer != null)
//both label and icon{
{
if (this._iconPosition != RelativePosition.TOP &&
this._iconPosition != RelativePosition.BOTTOM &&
this._iconPosition != RelativePosition.MANUAL)
{
newWidth += adjustedGap + this.currentIcon.width;
}
else if (this.currentIcon.width > newWidth)
//top, bottom, or manual{
{
newWidth = this.currentIcon.width;
}
}
}
}
//no label
else
{
{
newWidth = this.currentIcon.width;
}
}
Metadata
Metadata
Assignees
Labels
No labels