         
         let holder = Unmanaged.passRetained(Closure(closure: closure))
         
+        let pointer = UnsafeMutablePointer<Void>(holder.toOpaque())
+        
         #if os(Linux)
-            
-            let pointer = UnsafeMutablePointer<Void>(holder.toOpaque())
             
             var internalThread: pthread_t = 0
             

            pthread_detach(internalThread)
            
        #elseif os(OSX) || os(iOS) || os(watchOS) || os(tvOS)
            
            let pointer = UnsafeMutablePointer<Void>(OpaquePointer(bitPattern: holder))
            
            var internalThread: pthread_t? = nil
            

    
    private func ThreadPrivateMainDarwin(arg: UnsafeMutablePointer<Void>) -> UnsafeMutablePointer<Void>? {
        
        let unmanaged = Unmanaged<Thread.Closure>.fromOpaque(arg)
        
        unmanaged.takeUnretainedValue().closure()
        
