Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to fix warning init() is deprecated

Tags:

ios

swift

For the code line:

let bytesDecrypted   = UnsafeMutablePointer<Int>()

I am getting the warning: 'init()' is deprecated: init() will be removed in Swift 3. Use nil instead

What is the correct way to fix this warning?

like image 346
Ramis Avatar asked Mar 22 '16 11:03

Ramis


1 Answers

Do like this,

let bytesDecrypted: UnsafeMutablePointer<Int> = nil
like image 130
Venk Avatar answered Oct 22 '22 20:10

Venk