NSDictionary+MyCategory = crash?

Hi,
I have a static library in which I declare a category but when I use the declared method, the app simply crashes.


The catheroy method is dummy:


- (NSString *)formattedStringForKey:(NSString *)jsonXPath {     NSLog(@"formattedStringForKey");     return @"Test";
}




I set the -ObjC and  -all_load flags in the linker flags of the main app.

When I run the app in XCode, the entire XCode crashes ...

Any ideas what is going on?  


Unknown evaluation error: Unknown evaluation error
com.intellij.execution.ExecutionException: Unknown evaluation error
     at com.jetbrains.cidr.execution.debugger.backend.lldb.LLDBDriver.rawEvaluate(LLDBDriver.java:771)
     at com.jetbrains.cidr.execution.debugger.backend.lldb.LLDBDriver.evaluateWithDynamicType(LLDBDriver.java:700)
     at com.jetbrains.cidr.execution.debugger.backend.lldb.LLDBDriver.evaluate(LLDBDriver.java:695)
     at com.jetbrains.cidr.execution.debugger.backend.LLEvaluationContext.evaluate(LLEvaluationContext.java:116)
     at com.jetbrains.cidr.execution.debugger.backend.LLEvaluationContext.NSClassFromString(LLEvaluationContext.java:173)
     at com.jetbrains.cidr.execution.debugger.backend.LLEvaluationContext.isKindOfClass(LLEvaluationContext.java:165)
     at com.jetbrains.cidr.execution.debugger.evaluation.renderers.ValueRenderer.isSelfKindOfClass(ValueRenderer.java:92)
     at com.jetbrains.cidr.execution.debugger.evaluation.renderers.NSManagedObjectValueRenderer.<init>(NSManagedObjectValueRenderer.java:36)
     at com.jetbrains.cidr.execution.debugger.evaluation.renderers.NSManagedObjectValueRenderer.create(NSManagedObjectValueRenderer.java:127)
     at com.jetbrains.cidr.execution.debugger.backend.ValueRendererFactory.createNSManagedObjectValueRenderer(ValueRendererFactory.java:121)
     at com.jetbrains.cidr.execution.debugger.backend.ValueRendererFactory.createValueRenderer(ValueRendererFactory.java:51)
     at com.jetbrains.cidr.execution.debugger.evaluation.OCPhysicalValue.<init>(OCPhysicalValue.java:38)
     at com.jetbrains.cidr.execution.debugger.evaluation.OCPhysicalValue.<init>(OCPhysicalValue.java:26)
     at com.jetbrains.cidr.execution.debugger.evaluation.OCLocalValue.<init>(OCLocalValue.java:18)
     at com.jetbrains.cidr.execution.debugger.evaluation.OCValue.addAllTo(OCValue.java:112)
     at com.jetbrains.cidr.execution.debugger.OCStackFrame$2.run(OCStackFrame.java:131)
     at com.jetbrains.cidr.execution.debugger.OCDebugProcess$MyCommandProcessor.consume(OCDebugProcess.java:604)
     at com.jetbrains.cidr.execution.debugger.OCDebugProcess$MyCommandProcessor.consume(OCDebugProcess.java:598)
     at com.intellij.util.concurrency.QueueProcessor$2$1.run(QueueProcessor.java:103)
     at com.intellij.util.concurrency.QueueProcessor.runSafely(QueueProcessor.java:231)
     at com.intellij.util.concurrency.QueueProcessor$2.consume(QueueProcessor.java:100)
     at com.intellij.util.concurrency.QueueProcessor$2.consume(QueueProcessor.java:97)
     at com.intellij.util.concurrency.QueueProcessor$3$1.run(QueueProcessor.java:208)
     at com.intellij.util.concurrency.QueueProcessor.runSafely(QueueProcessor.java:231)
     at com.intellij.util.concurrency.QueueProcessor$3.run(QueueProcessor.java:205)
     at com.intellij.openapi.application.impl.ApplicationImpl$8.run(ApplicationImpl.java:454)
     at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:439)
     at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
     at java.util.concurrent.FutureTask.run(FutureTask.java:138)
     at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895)
     at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)
     at java.lang.Thread.run(Thread.java:680)
     at com.intellij.openapi.application.impl.ApplicationImpl$1$1.run(ApplicationImpl.java:152)

2 comments

I can't reproduce this with a simple project setup (see attachment). Could you please post a small test project to demonstrate this behavior?



Attachment(s):
test_crash_category.zip
0

hmm I can't also reproduce it in a isolated project :(

In my app it crashes all the time though. I tried switching to GDB instead od LLDB and it does not happen anymore ..

I'll post back if I find out something

0

Please sign in to leave a comment.