Replies: 1 comment 2 replies
-
The public entrypoint is: SyntaxFactory.ParseSyntaxTree. However, this will only give you a syntax tree.
To get semantic information, you need to make a Compilation, with the right metadata references and SyntaxTrees given to it. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Dear Roslyn compiler contributors,
I'm trying to trace the code at my local machine for the roslyn lexer and parser portion, in the routine "SyntaxTree ParseText()" of CSharpSyntaxTree.cs, should this routine generate the syntax tree? I see the code "var tree = new ParsedSyntaxTree" declaring the new instance of SyntaxTree, but I could not find the routine of concrete implementation for VerifySource() in the whole roslyn repository. Could you tell me which routine(s) or class file(s) are for constructing the ParseSyntaxTree so that the represented lexical and syntactic data structure can be further fed into the Semantic Model for type info analysis.
Thank you,
Bing Wang
Beta Was this translation helpful? Give feedback.
All reactions