as3hx icon indicating copy to clipboard operation
as3hx copied to clipboard

Conversion crashes on empty case with comment surrounded by curly braces

Open knetworx opened this issue 7 years ago • 0 comments

I had a few case statements in my AS3 code that looked like this:

case "somecase":
	{
		//trace("my debug output");
	} // Fall through intentionally
case "someothercase":
	{
		//success = true;
		break;
	}

expected result

case "somecase", "someothercase":
	{
		//success = true;
		break;
	}

actual result Conversion crashes - command line says the following:

Uncaught exception - Invalid field access : index

I can get the expected result if I change the original AS3 code to

case "updatedirect":
case "update":
	{
		//success = true;
		break;
	}

knetworx avatar Sep 27 '18 08:09 knetworx