GNOME Bugzilla – Bug 688610
Indentation incorrect if opening brace is in a line with other characters before it
Last modified: 2012-11-24 10:43:51 UTC
Created attachment 229324 [details] Expected indentation. (Might be different from default because of my settings) When the line contains other characters other than the opening bracket (commonly used in Vala and C#), the following lines are not indented correctly; they only have one tab as indentation. This shows up since the commit e27cade was pushed. A sample file is attached. This is actually in the "plugins/indentation-c-style" component.
Created attachment 229325 [details] Result
Forgot to mention that this doesn't always happen. Some blocks in my source codes are correctly indented, though the attached file is one of the smallest that I could find.
Created attachment 229740 [details] [review] indentation-c-style: Fix logic error from e27cade3ec1ce883182ff1b99637d781ae6b128c We should stop the loop when the number of left braces are more than or equal to the number of right braces.
Comment on attachment 229740 [details] [review] indentation-c-style: Fix logic error from e27cade3ec1ce883182ff1b99637d781ae6b128c Thank, I have committed it.