> On Aug 1, 2016, at 5:11 PM, Joe Groff via swift-dev <swift-dev@swift.org> 
> wrote:
> 
>> 
>> On Jul 31, 2016, at 5:12 AM, Charles Lane via swift-dev <swift-dev@swift.org 
>> <mailto:swift-dev@swift.org>> wrote:
>> 
>> I get a segmentation fault 11 at compile time with the 07/29 toolchain & 
>> Xcode 8 beta 3. Can anyone point me in right direction to fix this?
> 
> Should be addressed by https://github.com/apple/swift/pull/3918 
> <https://github.com/apple/swift/pull/3918>.
> 
> -Joe

August 2 nightly:

ld: library not found for -lswiftDispatch for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Code:

//-----------------------------------------------------------------------------
// MARK: Casting
//-----------------------------------------------------------------------------

// The Ashcast: Perform unsafe bitcast but only if the sizes equate

// Update for 3.0 8/2
infix operator -->
public func --><T, U>(value: T, target: U.Type) -> U? {
    guard MemoryLayout<T>.size == MemoryLayout<U>.size else { return nil }
    return unsafeBitCast(value, to: target)
}

// Beta 5
/// infix operator --> {}
/// public func --><T, U>(value: T, target: U.Type) -> U? {
///     guard sizeof(T.self) == sizeof(U.self) else { return nil }
///     return unsafeBitCast(value, to: target)
/// }


-- E
_______________________________________________
swift-dev mailing list
swift-dev@swift.org
https://lists.swift.org/mailman/listinfo/swift-dev

Reply via email to