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
C#: Include ASP.NET assemblies in the standalone extraction. #13876
base: main
Are you sure you want to change the base?
Conversation
…some minor re-writes.
…nt continue statement.
…s in standalone compilation.
| foreach (var valueMatch in regex.EnumerateMatches(line)) | ||
| { | ||
| // We can't get the group from the ValueMatch, so doing it manually: | ||
| if (GetGroup(line, valueMatch, groupPrefix) == value) | ||
| { | ||
| return true; | ||
| } | ||
| } |
Check notice
Code scanning / CodeQL
Missed opportunity to use Where Note
implicitly filters its target sequence
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is actually an error with the quality query.
- In this case the type of
regex.EnumerateMatches(line)is not an IEnumerable which means that we can't use the Linq extensions methods. - The statement in the loop uses early return.
| catch (Exception ex) | ||
| { | ||
| progressMonitor.FailedToReadFile(file, ex); | ||
| } |
Check notice
Code scanning / CodeQL
Generic catch clause Note
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are many different possible exceptions and we want to just catch all in case the file read fails.
This PR also contains a couple of bugfixes: