Skip to content

Conversation

@nojaf
Copy link
Contributor

@nojaf nojaf commented Sep 6, 2022

Somewhat fixes #13842.

@auduchinok can you give some more examples where the trivia list is smaller than the ident list?
I would personally like to address all these cases when the SynLongIdent is created.

The partial fix I've added to member this.IdentsWithTrivia doesn't feel right.
These lists should in theory never be out of sync. Even when recovery is kicking in.

@dsyme dsyme merged commit e050246 into dotnet:main Sep 23, 2022
@abonie
Copy link
Member

abonie commented Sep 23, 2022

I am getting an error running build.cmd on main and I believe this PR is to blame. This is the error:

tests\service\SyntaxTreeTests\SynIdentTests.fs(19,49): error FS3174: The union case 'ParsedImplFileInput' does not have a field named 'modules'.

@nojaf

@nojaf
Copy link
Contributor Author

nojaf commented Sep 23, 2022

ff0f892

@nojaf nojaf deleted the fix-synident-with-trivia branch September 25, 2022 16:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

SynLongIdent.IdentsWithTrivia throws exceptions

4 participants