Created
March 10, 2015 17:13
-
-
Save krzyzanowskim/feedae56ab4a7943e510 to your computer and use it in GitHub Desktop.
Swift NSArray wiredeness
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import Foundation | |
| let arr1 = [] | |
| arr1 is NSArray // true | |
| arr1 is NSMutableArray // false | |
| arr1.append(1) // 'NSArray' does not have a member named 'append' | |
| var arr2 = [] | |
| arr2 is NSArray // true | |
| arr2 is NSMutableArray // false | |
| arr2.append(1) // 'NSArray' does not have a member named 'append' | |
| var arr3 = [Int]() | |
| arr3 is NSArray // true | |
| arr3 is NSMutableArray // false | |
| arr3.append(1) // [1] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thanks just i need
var arr3 = Int
for fix my issue!...
regards.