Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[release/9.0-staging] Transform Span-based overloads to Enumerable in funcletizer#35719

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
roji merged 1 commit intodotnet:release/9.0-stagingfromroji:SpanOverloads9
Mar 5, 2025

Conversation

@roji
Copy link
Member

@rojiroji commentedMar 3, 2025

Backports part of#35339
Fixes#35100

Description

C# 14 (currently in preview) is introducingfirst-class spans, which changes the Roslyn overload resolution to prefer Span-based overloads in some cases. Unfortunately, the newly selected overloads, which have Span parameters, are unsupported in EF since the LINQ expression tree interpreter is used internally, and it does not support ref structs.

This problem already been fixed for EF 10 in#35339. However, users on older of EF Core who switch to .NET 10/C# 14 will still hit this issue. This PR proposes backporting the fix to EF Core 9.0 to ensure these users aren't affected.

Customer impact

Some very basic query patterns will start failing when trying to use EF Core 9.0 with C# 14, e.g.:

vardata=new[]{"Foo","Bar"};_=awaitcontext.Blogs.Where(b=>data.Contains(b.Name)).ToListAsync();

How found

Reported by users on 10.

Regression

Yes, in the combination of EF Core 9.0 and C# 14.

Testing

Older versions of EF aren't tested with later versions of C#/NET; manual testing was performed.

Risk

Very low - very targeted expression tree transformation; added quirk.

@rojirojienabled auto-merge (squash)March 4, 2025 19:22
@roji
Copy link
MemberAuthor

roji commentedMar 5, 2025

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@rojiroji merged commit67f52d8 intodotnet:release/9.0-stagingMar 5, 2025
7 checks passed
@rojiroji deleted the SpanOverloads9 branchMarch 5, 2025 07:22
This was referencedJul 22, 2025
This was referencedNov 24, 2025
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@AndriySvyrydAndriySvyrydAndriySvyryd approved these changes

Assignees

No one assigned

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

2 participants

@roji@AndriySvyryd

[8]ページ先頭

©2009-2025 Movatter.jp