Bug 1297 : Auto format problem with program deeper then 10 levels
Last modified: 2009-07-29 06:21




Status:
RESOLVED
Resolution:
FIXED -
Priority:
P5
Severity:
normal

 

Reporter:
hampus
Assigned To:
fry

Attachment Type Created Size Actions

Description:   Opened: 2009-07-28 16:09
Revision number:
1.0.3

Operating system:
Mac OSX 10.5.7

Code:
void setup(){
for(int a=0; a<1; a++){
for(int b=0; b<1; b++){
for(int c=0; c<1; c++){
for(int d=0; d<1; d++){
for(int e=0; e<1; e++){
for(int f=0; f<1; f++){
for(int g=0; g<1; g++){
for(int h=0; h<1; h++){
for(int i=0; i<1; i++){
for(int j=0; j<1; j++){
print("hello there!");
}
}
}
}
}
}
}
}
}
}
}

Red spew:
ava.lang.ArrayIndexOutOfBoundsException: 10
at processing.app.tools.AutoFormat.run(AutoFormat.java:564)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:461)
at
java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:269)
at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:190)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:184)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:176)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)

Description:
You can not auto format your code if it is "deeper" then 10 {}-levels.
(Note: Maybe I should build my program neater and avoid so many levels,
haha. Thanks for you awesomeness!)
Additional Comment #1 From fry 2009-07-29 06:21
heh, ok.. fixed for the next release after 1.0.5.