NullReferenceException in SyntaxFactory.ParseStatement() #17458
Labels
Area-Compilers
Bug
Concept-API
This issue involves adding, removing, clarification, or modification of an API.
Resolution-Fixed
The bug has been fixed and/or the requested behavior has been implemented
Milestone
Version Used:
NuGet Microsoft.CodeAnalysis 2.0.0-rc4
Steps to Reproduce:
SyntaxFactory.ParseStatement("private");
Expected Behavior:
Does not crash
Actual Behavior:
NullReferenceException:
This is because here we don't check the node for null:
http://source.roslyn.io/#Microsoft.CodeAnalysis.CSharp/Syntax/SyntaxFactory.cs,1780
The text was updated successfully, but these errors were encountered: