You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
#8414 brought performance improvement for SyntaxNodeAction registration.
Unfortunately, this creates some code duplication of the Execute method, especially regarding the checks on whether or not the SyntaxTree should be analyzed.
The idea is to follow what was done for RegisterNodeAction and apply it to other registration methods: Register for CompilationStartAction, do the checks or get it from the cache, and execute this action.
This should be possible for all registration actions except for:
CompilationStartAction
CompilationAction
Possible solutions:
Have the checks in CompilationStartActionContext, as of today (for RegisterNodeAction)
Have the checks in a dedicated method in SonarAnalysisContext.
The text was updated successfully, but these errors were encountered:
#8414 brought performance improvement for SyntaxNodeAction registration.
Unfortunately, this creates some code duplication of the Execute method, especially regarding the checks on whether or not the SyntaxTree should be analyzed.
Here are the checks to cache:
HasMatchingScope
for SyntaxNode registration #8399 only for SyntaxNodeActionThe idea is to follow what was done for RegisterNodeAction and apply it to other registration methods: Register for CompilationStartAction, do the checks or get it from the cache, and execute this action.
This should be possible for all registration actions except for:
CompilationStartAction
CompilationAction
Possible solutions:
The text was updated successfully, but these errors were encountered: