Posts

Post not yet marked as solved
2 Replies
286 Views
It is not possible to compile if the line 146 de the file "pointage.swift" is not in comment.  Otherwise we get this alarm :  The compiler is unable to type-check this expression in reasonable time; try breaking up the expression into distinct sub-expressions Pointage.swift
Posted
by crafh.
Last updated
.
Post not yet marked as solved
2 Replies
347 Views
We do not understand why , in the following code sequence , all the get functions return the right value , and not the first one SCNetworkInterfaceGetConfiguration which returns nothing ?< let arr: CFArray = SCNetworkInterfaceCopyAll() let interfaces: [SCNetworkInterface] = arr as! [SCNetworkInterface] for interface in interfaces { let intDic: CFDictionary? = SCNetworkInterfaceGetConfiguration(interface) if intDic != nil { print (intDic) } if let bsd: String = SCNetworkInterfaceGetBSDName(interface) as String? { print (bsd) } if let adress: String = SCNetworkInterfaceGetHardwareAddressString(interface) as String? { print (adress) } if let type: String = SCNetworkInterfaceGetInterfaceType(interface) as String? { print (type) } if let local: String = SCNetworkInterfaceGetLocalizedDisplayName(interface) as String? { print (local) } let typeId: CFTypeID = SCNetworkInterfaceGetTypeID() if let intSup: CFArray = SCNetworkInterfaceGetSupportedInterfaceTypes(interface) as CFArray? { print (intSup) } if let prot: [String] = SCNetworkInterfaceGetSupportedProtocolTypes(interface) as? [String] { print (prot) } }>macos 10.15.4 xcode 11.4.1
Posted
by crafh.
Last updated
.