Bug 12289 - Invalid cref:T:System.Collections.Generic.IList<T>
Summary: Invalid cref:T:System.Collections.Generic.IList<T>
Status: RESOLVED FIXED
Alias: None
Product: Xamarin Studio
Classification: Desktop
Component: C# Binding ()
Version: Trunk
Hardware: PC Mac OS
: Normal normal
Target Milestone: 4.0.9 (from master)
Assignee: Mike Krüger
URL:
Depends on:
Blocks:
 
Reported: 2013-05-17 14:29 UTC by Mikayla Hutchinson [MSFT]
Modified: 2013-06-24 16:18 UTC (History)
1 user (show)

Tags:
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:
Status:
RESOLVED FIXED

Description Mikayla Hutchinson [MSFT] 2013-05-17 14:29:51 UTC
When hovering over "List<string>" in the source editor I get the following error in the terminal:

WARNING [2013-05-17 14:25:32Z]: Invalid cref:T:System.Collections.Generic.IList<T>
System.NullReferenceException: Object reference not set to an instance of an object
  at ICSharpCode.NRefactory.Documentation.IdStringProvider.FindEntity (System.String idString, ITypeResolveContext context) [0x00047] in /Users/michael/Mono/monodevelop/main/external/nrefactory/ICSharpCode.NRefactory/Documentation/IdStringProvider.cs:383 
  at ICSharpCode.NRefactory.Documentation.DocumentationComment.ResolveCref (System.String cref) [0x00002] in /Users/michael/Mono/monodevelop/main/external/nrefactory/ICSharpCode.NRefactory/Documentation/DocumentationComment.cs:77 
  at MonoDevelop.Ide.TypeSystem.AmbienceService.GetCref (ITypeResolveContext ctx, System.String cref) [0x00032] in /Users/michael/Mono/monodevelop/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.TypeSystem/AmbienceService.cs:211
Comment 1 Mikayla Hutchinson [MSFT] 2013-05-17 15:06:55 UTC
It looks like it's having trouble with the format of the crefs in the content it's getting from MonoDoc.
Comment 2 Mike Krüger 2013-05-24 03:32:34 UTC
I fixed the exception - but the problem is the cref.

T:System.Collections.Generic.IList<T> is not a valid ID string.

The ID string would be: T:System.Collections.Generic.IList{T}
Comment 3 Mikayla Hutchinson [MSFT] 2013-05-28 14:19:44 UTC
Technically correct, but the problem is we have many of these in our MonoDoc based docs, and MonoDoc itself handles <> as well as {}. So the pragmatic solution would be to allow <>.
Comment 4 Mike Krüger 2013-05-29 01:43:43 UTC
The exception no longer happens. I'm not really for the idea to allow <> because that would taught our users to use <> in the crefs in their xml docs - which is simply wrong and wont work with other tools. (esp. MS) It's not that much of an issue in the tooltips.
Comment 5 Mikayla Hutchinson [MSFT] 2013-05-29 10:46:05 UTC
Can we at least special case it so we can handle these when they come from MonoDoc? It's "valid" in MonoDoc.
Comment 6 Mike Krüger 2013-05-29 11:59:19 UTC
I put it on the todo pile. But y for monodoc only it may be possible.
Comment 7 Mike Krüger 2013-06-07 04:22:55 UTC
fixed

btw. I found a nrefactory bug as well doing this one - therefore it was well spent time :)
Comment 8 PJ 2013-06-24 16:18:49 UTC
This bug was marked as fixed for Xamarin Studio 4.0.9, which is currently in the beta channel. Try it out!