I'm having a Swift script in which I have to use SHA hashing or MD5. If I want to write functions for that I have to use Objective-C code. But it is a Swift script, so, how can I add/use Objective-C in that script? Can I make bridging header for it or is it impossible? Thanks for your answer.
Asked
Active
Viewed 66 times
0
-
1Did you try one of these solutions? http://stackoverflow.com/questions/24002369/how-to-call-objective-c-code-from-swift – Eric Aya Sep 21 '16 at 13:47
-
Yes, but how create bridging header for Swift SCRIPT? I'm running it from terminal as a bash script. – MattCodes Sep 21 '16 at 13:51
-
1If you are talking about Swift scripts which are text files starting with `#!/usr/bin/swift`: You cannot include Objective-C code (or any code from other modules). – Martin R Sep 21 '16 at 14:12
-
Is there a list of frameworks that I can use in Swift script? – MattCodes Sep 21 '16 at 14:26