-
Notifications
You must be signed in to change notification settings - Fork 4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding semicolon inbetween property name and { get; set; } invalidates rest of the document (excess errors) #52
Comments
Although the intention might have been to declare a property, That makes the |
@paulomorgado of course, but invalidating the entire remaining document seems way overkill. You still need to balance the |
Interesting error recovery case :) |
I'm curious. How would you recover from that error, @NTaylorMullen? |
@paulomorgado If a user were to type: To sum it all up, if you encounter any variation of I'm not entirely familiar with the parsing logic/behavior done in Roslyn so I apologize for not being able to go more into familiar detail but that is how we would do it in Razor. |
Use new roslyn to fix options exceptions
Repro:
Note the
;
afterMyProperty
and before{ get; set; }
Expected:
Rest of document not being invalidated and an error that points to the property.
Notes:
When generating code for Razor there have been some cases of users adding semicolons after
@inject
statements resulting in the entire document being invalidated (tons of errors) afterThe text was updated successfully, but these errors were encountered: