Inherits from NSObject
Declared in RACBacktrace.h

Overview

Preserves backtraces across asynchronous calls.

On OS X, you can enable the automatic capturing of asynchronous backtraces (in Debug builds) by setting the DYLD_INSERT_LIBRARIES environment variable to @executable_path/../Frameworks/ReactiveCocoa.framework/ReactiveCocoa in your scheme’s Run action settings.

On iOS, your project and RAC will automatically use the rac_ GCD functions (declared above) for asynchronous work. Unfortunately, unlike OS X, it’s impossible to capture backtraces inside NSOperationQueue or other code outside of your project.

Once backtraces are being captured, you can po [[RACBacktrace backtrace]](#//api/name/backtrace) in the debugger to print them out at any time. You can even set up an alias in ~/.lldbinit to do so:

command alias racbt po [RACBacktrace backtrace]

Tasks

Properties

callStackSymbols

@property (nonatomic, copy, readonly) NSArray *callStackSymbols
Discussion

The call stack of this backtrace’s thread.

Declared In

RACBacktrace.h

previousThreadBacktrace

@property (nonatomic, strong, readonly) RACBacktrace *previousThreadBacktrace
Discussion

The backtrace from any previous thread.

Declared In

RACBacktrace.h

Class Methods

backtrace

+ (instancetype)backtrace
Discussion

Captures the current thread’s backtrace, appending it to any backtrace from a previous thread.

Declared In

RACBacktrace.h

backtraceIgnoringFrames:

+ (instancetype)backtraceIgnoringFrames:(NSUInteger)ignoreCount
Discussion

Same as backtrace, but omits the specified number of frames at the top of the stack (in addition to this method itself).

Declared In

RACBacktrace.h