Files
swift-numerics/Package.swift
T
Steve (Numerics) Canon 919f13ce2e Restore the NumericShims module, use it instead of silgen_name.
I had thought that we could get away with just using @_silgen_name to wrap the platform libm functions in ElementaryFunctions conformances, but that's now failing in release builds when both ElementaryFunctions and the Platform module are imported (and actually crashing swiftc).

Fall back on the previous strategy of using C header shims. This adds an extra layer of source abstraction, but we're still able to optimize it away at compile time, even in unoptimized builds, so we can live with it for now.
2019-08-01 22:12:03 -04:00

33 lines
1.1 KiB
Swift

// swift-tools-version:5.0
//===--- Package.swift ----------------------------------------*- swift -*-===//
//
// This source file is part of the Swift.org open source project
//
// Copyright (c) 2019 Apple Inc. and the Swift project authors
// Licensed under Apache License v2.0 with Runtime Library Exception
//
// See https://swift.org/LICENSE.txt for license information
// See https://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//
//===----------------------------------------------------------------------===//
import PackageDescription
let package = Package(
name: "swift-numerics",
products: [
.library(name: "Complex", targets: ["Complex"]),
.library(name: "ElementaryFunctions", targets: ["ElementaryFunctions"]),
],
dependencies: [
],
targets: [
.target(name: "Complex", dependencies: ["ElementaryFunctions"]),
.target(name: "ElementaryFunctions", dependencies: ["NumericsShims"]),
.target(name: "NumericsShims", dependencies: []),
.testTarget(name: "ComplexTests", dependencies: ["Complex"]),
.testTarget(name: "ElementaryFunctionTests", dependencies: ["ElementaryFunctions"]),
]
)