Skip to content
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

Bugfix for extension methods: Treat System.Private.CoreLib as a system lib for extension method search #17799

Merged
merged 8 commits into from
Sep 26, 2024

Conversation

T-Gro
Copy link
Member

@T-Gro T-Gro commented Sep 26, 2024

Addresses #17793
Before it, extension method resolution did not work for system assemblies if the compilation was NOT using reference assemblies.

The usesdkrefs- is a switch which dotnetinteractive uses.
Without this switch, the problem does not reproduce.

Copy link
Contributor

github-actions bot commented Sep 26, 2024

❗ Release notes required


✅ Found changes and release notes in following paths:

Change path Release notes path Description
src/Compiler docs/release-notes/.FSharp.Compiler.Service/9.0.200.md

@T-Gro T-Gro marked this pull request as ready for review September 26, 2024 16:35
@T-Gro T-Gro requested a review from a team as a code owner September 26, 2024 16:35
@T-Gro T-Gro self-assigned this Sep 26, 2024
@T-Gro T-Gro added this to the September-2024 milestone Sep 26, 2024
@T-Gro
Copy link
Member Author

T-Gro commented Sep 26, 2024

/backport to release/dev17.11

This reverts commit dca40ae.
@dotnet dotnet deleted a comment from github-actions bot Sep 26, 2024
@dotnet dotnet deleted a comment from github-actions bot Sep 26, 2024
@dotnet dotnet deleted a comment from github-actions bot Sep 26, 2024
@T-Gro
Copy link
Member Author

T-Gro commented Sep 26, 2024

/backport to release/dev17.11

Copy link
Contributor

Started backporting to release/dev17.11: https://github.com/dotnet/fsharp/actions/runs/11057164787

Copy link
Contributor

@T-Gro backporting to release/dev17.11 failed, the patch most likely resulted in conflicts:

$ git am --3way --empty=keep --ignore-whitespace --keep-non-patch changes.patch

Applying: Treat System.Private.CoreLib as a system lib for extension method search
Applying: usessdkrefs is not a valid option for desktop compiler
Applying: notes
Using index info to reconstruct a base tree...
A	docs/release-notes/.FSharp.Compiler.Service/9.0.200.md
Falling back to patching base and 3-way merge...
CONFLICT (modify/delete): docs/release-notes/.FSharp.Compiler.Service/9.0.200.md deleted in HEAD and modified in notes. Version notes of docs/release-notes/.FSharp.Compiler.Service/9.0.200.md left in tree.
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
hint: When you have resolved this problem, run "git am --continue".
hint: If you prefer to skip this patch, run "git am --skip" instead.
hint: To restore the original branch and stop patching, run "git am --abort".
hint: Disable this message with "git config advice.mergeConflict false"
Patch failed at 0003 notes
Error: The process '/usr/bin/git' failed with exit code 128

Please backport manually!

Copy link
Contributor

@T-Gro an error occurred while backporting to release/dev17.11, please check the run log for details!

Error: git am failed, most likely due to a merge conflict.

@KevinRansom KevinRansom enabled auto-merge (squash) September 26, 2024 20:25
@KevinRansom KevinRansom merged commit 94f9b40 into main Sep 26, 2024
32 checks passed
esbenbjerre pushed a commit to esbenbjerre/fsharp that referenced this pull request Sep 30, 2024
…m lib for extension method search (dotnet#17799)

* Treat System.Private.CoreLib as a system lib for extension method search

* usessdkrefs is not a valid option for desktop compiler

* notes

* Revert "notes"

This reverts commit dca40ae.

* Release notes back

* get rid of looksLikeSystemAssembly  in ilread, it is not needed

---------

Co-authored-by: Kevin Ransom (msft) <codecutter@hotmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

Updating dotnet interactive to FSharp.Core and FSharp.Compiler.Service 8.0.400 causes test errors
3 participants