Bug 11966 - Code Completion Errors with /// Comments
Summary: Code Completion Errors with /// Comments
Alias: None
Product: Xamarin Studio
Classification: Desktop
Component: Text Editor ()
Version: 4.0.4
Hardware: Macintosh Mac OS
: Normal normal
Target Milestone: ---
Assignee: Mike Krüger
Depends on:
Reported: 2013-04-25 11:31 UTC by Kevin Mullins
Modified: 2013-05-17 07:02 UTC (History)
1 user (show)

Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and 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 Links.

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.

Related Links:

Description Kevin Mullins 2013-04-25 11:31:07 UTC
I has found several issues while using the /// style comment blocks. First, if you has a sentence with blank spaces after the cursor and you hit the Enter key to go to the next line it fubar's the comment block on the next line. Example:

///<summary>This is a long comment [cursor here]  </summary>

If I hit enter, I'll get the following:

///<summary>This is a long comment
  [cursor here]///

(note the extra spaces and the location of the cursor)

Also if you are trying to add other decorators like <c></c> and the cursor is touching another < code completion goes bonkers!

This doesn't work:
///<summary>This is a long comment [cursor here]</summary>
If I type <c> code completion can sometimes crash or lockup XS but I usually get something totally random in <>

This does work:
///<summary>This is a long comment [cursor here] </summary>
If I type <c> now I'll get the proper <c></c> block but it will cause the above issue when I hit enter

The auto generated comment for ID is also quite bizarre. If I have any parameter with "ID" in it, it's replaced with "I." in the comment. Example:

/// <param name='playerID'>
/// Player I.
/// </param>
Comment 1 Mike Krüger 2013-05-17 07:02:14 UTC

(except the 'strange comment' thing - y the comment generator can be improved, but it's not atm very high on my todo list)