Bug 8906 - [codeanalysis] NRE in CodeIssues.NRefactoryIssueProvider
Summary: [codeanalysis] NRE in CodeIssues.NRefactoryIssueProvider
Status: RESOLVED FIXED
Alias: None
Product: Xamarin Studio
Classification: Desktop
Component: Text Editor ()
Version: 3.1.x
Hardware: Macintosh Mac OS
: --- normal
Target Milestone: ---
Assignee: Mike Krüger
URL:
Depends on:
Blocks:
 
Reported: 2012-12-12 11:26 UTC by Stephen Shaw
Modified: 2012-12-13 00:48 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 Stephen Shaw 2012-12-12 11:26:13 UTC
I get this error just opening up a solution.  There are a few files that are opened as well when the solution opens.






ERROR [2012-12-12 09:22:31Z]: CodeAnalysis: Got exception in inspector 'MonoDevelop.CSharp.Refactoring.CodeIssues.NRefactoryIssueProvider'
System.NullReferenceException: Object reference not set to an instance of an object
  at ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowGraphBuilder.CreateStartNode (ICSharpCode.NRefactory.CSharp.Statement statement) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowGraphBuilder+NodeCreationVisitor.VisitIfElseStatement (ICSharpCode.NRefactory.CSharp.IfElseStatement ifElseStatement, ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowNode data) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.IfElseStatement.AcceptVisitor[ControlFlowNode,ControlFlowNode] (IAstVisitor`2 visitor, ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowNode data) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowGraphBuilder+NodeCreationVisitor.HandleStatementList (ICSharpCode.NRefactory.CSharp.AstNodeCollection`1 statements, ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowNode source) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowGraphBuilder+NodeCreationVisitor.VisitBlockStatement (ICSharpCode.NRefactory.CSharp.BlockStatement blockStatement, ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowNode data) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.BlockStatement.AcceptVisitor[ControlFlowNode,ControlFlowNode] (IAstVisitor`2 visitor, ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowNode data) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowGraphBuilder+NodeCreationVisitor.VisitIfElseStatement (ICSharpCode.NRefactory.CSharp.IfElseStatement ifElseStatement, ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowNode data) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.IfElseStatement.AcceptVisitor[ControlFlowNode,ControlFlowNode] (IAstVisitor`2 visitor, ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowNode data) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowGraphBuilder+NodeCreationVisitor.HandleStatementList (ICSharpCode.NRefactory.CSharp.AstNodeCollection`1 statements, ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowNode source) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowGraphBuilder+NodeCreationVisitor.VisitBlockStatement (ICSharpCode.NRefactory.CSharp.BlockStatement blockStatement, ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowNode data) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.BlockStatement.AcceptVisitor[ControlFlowNode,ControlFlowNode] (IAstVisitor`2 visitor, ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowNode data) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowGraphBuilder.BuildControlFlowGraph (ICSharpCode.NRefactory.CSharp.Statement statement, System.Func`3 resolver, ICSharpCode.NRefactory.CSharp.TypeSystem.CSharpTypeResolveContext typeResolveContext, CancellationToken cancellationToken) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowGraphBuilder.BuildControlFlowGraph (ICSharpCode.NRefactory.CSharp.Statement statement, ICSharpCode.NRefactory.CSharp.Resolver.CSharpAstResolver resolver, CancellationToken cancellationToken) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.Analysis.ControlFlowGraphBuilder.BuildControlFlowGraph (ICSharpCode.NRefactory.CSharp.Statement statement, CancellationToken cancellationToken) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.Refactoring.AccessToClosureIssue+GatherVisitor.CollectIssues (ICSharpCode.NRefactory.CSharp.Refactoring.Environment env, System.String variableName) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.Refactoring.AccessToClosureIssue+GatherVisitor.CheckVariable (IVariable variable, ICSharpCode.NRefactory.CSharp.Statement env) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.Refactoring.AccessToClosureIssue+GatherVisitor.VisitParameterDeclaration (ICSharpCode.NRefactory.CSharp.ParameterDeclaration parameterDeclaration) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.ParameterDeclaration.AcceptVisitor (IAstVisitor visitor) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.DepthFirstAstVisitor.VisitChildren (ICSharpCode.NRefactory.CSharp.AstNode node) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.GatherVisitorBase.VisitChildren (ICSharpCode.NRefactory.CSharp.AstNode node) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.DepthFirstAstVisitor.VisitMethodDeclaration (ICSharpCode.NRefactory.CSharp.MethodDeclaration methodDeclaration) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.MethodDeclaration.AcceptVisitor (IAstVisitor visitor) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.DepthFirstAstVisitor.VisitChildren (ICSharpCode.NRefactory.CSharp.AstNode node) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.GatherVisitorBase.VisitChildren (ICSharpCode.NRefactory.CSharp.AstNode node) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.DepthFirstAstVisitor.VisitTypeDeclaration (ICSharpCode.NRefactory.CSharp.TypeDeclaration typeDeclaration) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.TypeDeclaration.AcceptVisitor (IAstVisitor visitor) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.DepthFirstAstVisitor.VisitChildren (ICSharpCode.NRefactory.CSharp.AstNode node) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.GatherVisitorBase.VisitChildren (ICSharpCode.NRefactory.CSharp.AstNode node) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.DepthFirstAstVisitor.VisitNamespaceDeclaration (ICSharpCode.NRefactory.CSharp.NamespaceDeclaration namespaceDeclaration) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.NamespaceDeclaration.AcceptVisitor (IAstVisitor visitor) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.DepthFirstAstVisitor.VisitChildren (ICSharpCode.NRefactory.CSharp.AstNode node) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.GatherVisitorBase.VisitChildren (ICSharpCode.NRefactory.CSharp.AstNode node) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.DepthFirstAstVisitor.VisitSyntaxTree (ICSharpCode.NRefactory.CSharp.SyntaxTree syntaxTree) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.SyntaxTree.AcceptVisitor (IAstVisitor visitor) [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.GatherVisitorBase.GetIssues () [0x00000] in <filename unknown>:0 
  at ICSharpCode.NRefactory.CSharp.Refactoring.AccessToClosureIssue.GetIssues (ICSharpCode.NRefactory.CSharp.Refactoring.BaseRefactoringContext context) [0x00000] in <filename unknown>:0 
  at MonoDevelop.CSharp.Refactoring.CodeIssues.NRefactoryIssueProvider+<GetIssues>c__Iterator16.MoveNext () [0x00000] in <filename unknown>:0 
  at MonoDevelop.CodeIssues.CodeAnalysisRunner+<Check>c__AnonStorey25.<>m__3A (MonoDevelop.CodeIssues.CodeIssueProvider provider) [0x00000] in <filename unknown>:0
Comment 1 Mike Krüger 2012-12-13 00:48:05 UTC
Should be fixed in the next version.