Skip to content

Instantly share code, notes, and snippets.

@jpohhh
jpohhh / gist:5167390
Last active Dec 14, 2015
testing Xcode 4.6.1 and blocks + lldb
View gist:5167390
UIViewController *controller = [[UIViewController alloc] init];
[controller loadView];
double delayInSeconds = 2.0;
dispatch_time_t popTime = dispatch_time(DISPATCH_TIME_NOW, (int64_t)(delayInSeconds * NSEC_PER_SEC));
dispatch_after(popTime, dispatch_get_main_queue(), ^(void){
NSLog(@"Statement so block captures controller: %@", controller);
NSLog(@"Need set breakpoint here. Testing by typing po [controller view] into debugger");
});
View gist:1272969
James-OLearys-MacBook:desktop jpo$ python coredata.py /Users/jpo/Dropbox/Work/Refulgent/Code/Ambur/Model/Waiter_Helper.xcdatamodeld/Waiter_Helper\ 18.xcdatamodel
/var/folders/23/tyg4p1m55sb3yg8xymp795bc0000gn/T/tmpGfaetE/model.mom
Traceback (most recent call last):
File "coredata.py", line 42, in <module>
entities = model.entities().sortedArrayUsingDescriptors_(descriptors)
AttributeError: 'NoneType' object has no attribute 'entities'