Skip to content

Conversation

@Sergio0694
Copy link
Member

Follow up to #2083.

This PR applies the same refactoring to all ___Impl non-projected types in WinRT.Runtime, for consistency.
With this change, all IIDs are always either in WellKnownInterfaceIIDs, or in a generated InterfaceIIDs type.

Replaces direct references to interface implementation IIDs with constants from WellKnownWindowsInterfaceIIDs across multiple ABI and interop files. This change improves consistency and maintainability by centralizing interface ID definitions.
Replaces direct references to interface IID getters (e.g., IUnknownImplget_IID) with WellKnownInterfaceIIDs static properties throughout the InteropTypeDefinitionBuilder classes. Updates InteropReferences to provide WellKnownInterfaceIIDs member references and removes obsolete per-implementation IID getters. This centralizes and simplifies access to well-known interface IIDs.
Replaced direct IID assignments from implementation classes with references to WindowsRuntime.InteropServices.WellKnownInterfaceIIDs constants for standard interfaces. This improves clarity and ensures consistency in IID usage.
Prefixed references to WindowsRuntime.InteropServices.WellKnownInterfaceIIDs and related implementation classes with 'global::' to ensure correct namespace resolution and avoid potential conflicts. This change improves code clarity and compatibility, especially in projects with custom or nested namespaces.
@Sergio0694 Sergio0694 merged commit 5ab32f0 into staging/3.0 Nov 1, 2025
10 checks passed
@Sergio0694 Sergio0694 deleted the user/sergiopedri/iid-refactor2 branch November 1, 2025 18:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants