Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
Mono organizations on
GitHub to continue tracking issues. Bugzilla will remain
available for reference in read-only mode. We will continue to work
on open Bugzilla bugs, copy them to the new locations
as needed for follow-up, and add the new items under Related
Our sincere thanks to everyone who has contributed on this bug
tracker over the years. Thanks also for your understanding as we
make these adjustments and improvements for the future.
Please create a new report on
Developer Community or GitHub with
your current version information, steps to reproduce, and relevant error
messages or log files if you are hitting an issue that looks similar to
this resolved bug and you do not yet see a matching new report.
The on the fly formatter formats too much.
When it's triggered by a semicolon, it should format only that statement. When it's trigged by a closing brace, it should only format that block.
No I don't think so.
The formatting should always try to enforce the style to the whole file. That it works currently just inside the method is a drawback.
At best anything would be formatted always. That it works atm just on ; and } is a drawback.
This is a problem because it creates a lot of VCS noise on existing code. The on the fly formatter is supposed to fix the code you're editing, not the whole file.
It's just formatting the method - which I find reasonable.
I agree with Michael, the on-the-fly formatter must only format the statement or block you are modifying. Formatting the whole file or even the whole method goes against the basic rule of not doing formatting changes together with code changes. The on-the-fly formatting option is not about enforcing the formatting policies, but about assisting the user in writing correctly formatted code. There may be many reasons why a file may have incorrectly formatted code. Maybe the formatting policy has changed, or maybe who wrote the code didn't have autoformatting enabled and used some incorrect formatting in some cases. But in any case, MD has no right to reformat code at will.
it does not format the whole file - it even just formats just up to caret position from method begin.
it doesn't no longer format on ';'
OK, filed an enhancement for formatting statements on the final semicolon - bug 4884 :)