Last active
August 29, 2015 13:57
-
-
Save mikeash/9473989 to your computer and use it in GitHub Desktop.
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
| void f(void) { | |
| char *CArray[] = { // correct! | |
| "a", | |
| "b", | |
| "c" | |
| }; | |
| CGRect CInitializer = { // correct! | |
| .origin = { | |
| 0, | |
| 0 | |
| }, | |
| .size = { | |
| 42, | |
| 42 | |
| } | |
| }; | |
| id CBlockArray[] = { // not bad! | |
| ^{ | |
| printf("x"); | |
| }, | |
| [1] = ^{ | |
| printf("y"); | |
| } | |
| }; | |
| NSArray *ObjCArray = @[ // insane! | |
| @"a", | |
| @"b", | |
| @"c" | |
| ]; | |
| NSDictionary *ObjCDictionary = @{ // insane! | |
| @"a" : @"b", | |
| @"here's a nested dictionary, which gets even crazier" : @{ | |
| @"wat" : @"seriously" | |
| }, | |
| @"now we're over here?" : @"why?", | |
| @"let's try a nested array" : @[ | |
| @"at least it's mildly consistent", | |
| @"sorta" | |
| ], | |
| }; | |
| NSArray *ObjCBlockArray = @[ // WAT | |
| ^{ | |
| printf("x"); | |
| }, | |
| ^{ | |
| printf("y"); | |
| } | |
| ]; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It's just frustrating because the team developing Xcode are also using it and seeing this crap too and just not fixing it.