Skip to content

Conversation

@jjonescz
Copy link
Member

@jjonescz jjonescz commented Nov 3, 2025

Fixes #80986.

Also ensures both partial event parts have consistent IsWindowsRuntimeEvent (this discrepancy appeared during testing).

@jjonescz jjonescz changed the title Fix cycle in partial event interface implemenation Fix cycle in partial event interface implementation Nov 3, 2025
@jjonescz jjonescz marked this pull request as ready for review November 4, 2025 11:52
@jjonescz jjonescz requested a review from a team as a code owner November 4, 2025 11:52

private EmitData GetEmitData() => _emitData ?? throw new InvalidOperationException("Must call Emit first");

internal PortableExecutableReference GetImageReference(
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📝 inspired by GetCompilation(...).EmitToImageReference - there was no equivalent for CompileAndVerify afaict

Copy link
Contributor

@AlekseyTs AlekseyTs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM (commit 1)

@jjonescz
Copy link
Member Author

jjonescz commented Nov 5, 2025

@RikkiGibson @dotnet/roslyn-compiler for a second review, thanks

1 similar comment
@jjonescz
Copy link
Member Author

@RikkiGibson @dotnet/roslyn-compiler for a second review, thanks

Assert.Null(e2.PartialDefinitionPart);
}

[Fact]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

WorkItem? And on other tests.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think these are not directly related to the issue, they are just a byproduct of the fix. (One is actually just testing a pre-existing behavior.) The related tests (InterfaceImplementation*) have WorkItem attribute.

@jjonescz jjonescz merged commit 43a5328 into dotnet:main Nov 11, 2025
25 checks passed
@jjonescz jjonescz deleted the 80986-PartialEvent-StackOverflow branch November 11, 2025 12:13
@dotnet-policy-service dotnet-policy-service bot added this to the Next milestone Nov 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

CSC and DevEnv crash with stack overflow when partial class with partial event implements interface

3 participants