-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Merge Semmle.Extraction into Semmle.Extraction.CSharp
#17984
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
Conversation
| catch (Exception ex) // lgtm[cs/catch-of-all-exceptions] | ||
| { | ||
| ExtractionError($"Uncaught exception. {ex.Message}", null, CreateLocation(), ex.StackTrace); | ||
| } |
Check notice
Code scanning / CodeQL
Generic catch clause Note
| catch (Exception ex) // lgtm[cs/catch-of-all-exceptions] | ||
| { | ||
| Message message; | ||
|
|
||
| if (node is not null) | ||
| { | ||
| message = Message.Create(this, ex.Message, node, ex.StackTrace); | ||
| } | ||
| else if (symbol is not null) | ||
| { | ||
| message = Message.Create(this, ex.Message, symbol, ex.StackTrace); | ||
| } | ||
| else if (ex is InternalError ie) | ||
| { | ||
| message = new Message(ie.Text, ie.EntityText, CreateLocation(ie.Location), ex.StackTrace); | ||
| } | ||
| else | ||
| { | ||
| message = new Message($"Uncaught exception. {ex.Message}", null, CreateLocation(), ex.StackTrace); | ||
| } | ||
|
|
||
| ExtractionError(message); | ||
| } |
Check notice
Code scanning / CodeQL
Generic catch clause Note
michaelnebel
left a comment
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.
Very nice @tamasvajk !
csharp/extractor/Semmle.Extraction.CSharp/Entities/Base/CachedEntityFactory.cs
Show resolved
Hide resolved
michaelnebel
left a comment
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.
Great!
No description provided.