The decompiler throws exceptions on a number of the mpy files from the 51515.
One type is due to parsing of the enum keys and values. Some values have curly brackets which causes the simple splitting on these characters to fail. This change replaces the use of split() with a line by line approach.
There is also a situation where stage4_lbd() can be called with i==4 which is used as an index into a list of size 4 causing an index error. The array has been extended by one, but it is not clear if the value used is always correct. The exception is avoided, nonetheless.
The decompiler throws exceptions on a number of the mpy files from the 51515.
One type is due to parsing of the enum keys and values. Some values have curly brackets which causes the simple splitting on these characters to fail. This change replaces the use of split() with a line by line approach.
There is also a situation where stage4_lbd() can be called with i==4 which is used as an index into a list of size 4 causing an index error. The array has been extended by one, but it is not clear if the value used is always correct. The exception is avoided, nonetheless.