Skip to content

Commit 4dd71a4

Browse files
authored
Rename the new _GUID clang module to _GUIDDef. (#84466)
This PR changes the name of the clang module introduced in #83914 from `_GUID` to `_GUIDDef`. This change is necessary because the Windows SDK declares a type named `_GUID` and Swift gets confused when a module and a type have the same name. This confusion is the motivation for [SE-0491](https://github.com/swiftlang/swift-evolution/blob/main/proposals/0491-module-selectors.md), but we can't just wait for a fix because the new module is a source-breaking change and clients won't be able to adopt the proposed syntax for some time.
1 parent f7bef8d commit 4dd71a4

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

stdlib/public/Platform/winsdk_shared.modulemap

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
//
1111
//===----------------------------------------------------------------------===//
1212

13-
module _GUID {
13+
module _GUIDDef {
1414
header "guiddef.h"
1515
export *
1616
}

stdlib/public/Windows/WinSDK.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
//===----------------------------------------------------------------------===//
1212

1313
@_exported import ucrt
14-
@_exported import _GUID
14+
@_exported import _GUIDDef
1515
@_exported import WinSDK // Clang module
1616

1717
// WinBase.h

0 commit comments

Comments
 (0)