dotnet/roslyn
Refactor `CheckFeatureAvailability` to not accept a `Location` parameter
オープン
#68,935 opened on 2023/07/08
Area-CompilersArea-Performancehelp wanted
Repository metrics
- Stars
- (20,414 個のスター)
- PR merge metrics
- (平均マージ 6d 17h) (30d で 256 merged PRs)
説明
Currently, CheckFeatureAvailability overloads take a Location parameter. Causing caller to call syntaxNode.Location which allocates a SourceLocation. At the end, if the feature is available, the allocation is thrown away.
Example:
Not sure how much this pattern is hit, but it's good to optimize this anyway.