Skip to content

Avoid enumerator boxing in XamlSchemaContext.UpdateNamespaceByUriList#6282

Merged
dipeshmsft merged 1 commit intodotnet:mainfrom
stephentoub:updatenamespaceboxing
May 5, 2022
Merged

Avoid enumerator boxing in XamlSchemaContext.UpdateNamespaceByUriList#6282
dipeshmsft merged 1 commit intodotnet:mainfrom
stephentoub:updatenamespaceboxing

Conversation

@stephentoub
Copy link
Member

Description

UpdateNamespaceByUriList has an IList<T> but is enumerating it with foreach, resulting in boxing the underlying list or array's enumerator.

Customer Impact

Unnecessary allocation.

Regression

No

Testing

CI

Risk

Minimal

@stephentoub stephentoub requested a review from a team as a code owner March 18, 2022 14:15
@ghost ghost added the PR metadata: Label to tag PRs, to facilitate with triage label Mar 18, 2022
@ghost ghost requested review from SamBent, dipeshmsft and singhashish-wpf March 18, 2022 14:15
@ghost ghost assigned stephentoub May 4, 2022
@dipeshmsft dipeshmsft merged commit 883887d into dotnet:main May 5, 2022
@ghost ghost locked as resolved and limited conversation to collaborators Jun 8, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

PR metadata: Label to tag PRs, to facilitate with triage

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants