mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
[Swiftify] Fix Package.swift
Swift packages are normally in `Sources/<target-name>`, but SwiftifyImportMacro is in `Sources/SwiftMacros`, and SwiftifyImport is in `<root>/stdlib/public/core`, which is outside the package root. This sets the correct path for SwiftifyImportMacro, and creates a directory `Sources/PublicCorePortal` with a symlink to `SwiftifyImport.swift`. It also enables LifetimeDependence for SwiftifyImport. These changes are purely to provide information to SourceKit - this file isn't actually used by CMake.
This commit is contained in:
@@ -35,12 +35,15 @@ let package = Package(
|
||||
.product(name: "SwiftParser", package: "swift-syntax"),
|
||||
.product(name: "SwiftSyntax", package: "swift-syntax"),
|
||||
.product(name: "SwiftSyntaxBuilder", package: "swift-syntax"),
|
||||
.product(name: "SwiftSyntaxMacro", package: "swift-syntax")
|
||||
]
|
||||
.product(name: "SwiftSyntaxMacros", package: "swift-syntax")
|
||||
],
|
||||
path: "Sources/SwiftMacros",
|
||||
),
|
||||
.target(
|
||||
name: "SwiftifyImport",
|
||||
dependencies: ["SwiftifyImportMacro"]
|
||||
dependencies: ["SwiftifyImportMacro"],
|
||||
path: "Sources/PublicCorePortal",
|
||||
swiftSettings: [.enableExperimentalFeature("LifetimeDependence")],
|
||||
)
|
||||
]
|
||||
)
|
||||
|
||||
1
lib/Macros/Sources/PublicCorePortal/SwiftifyImport.swift
Symbolic link
1
lib/Macros/Sources/PublicCorePortal/SwiftifyImport.swift
Symbolic link
@@ -0,0 +1 @@
|
||||
../../../../stdlib/public/core/SwiftifyImport.swift
|
||||
Reference in New Issue
Block a user