Learn R Programming

winch (version 0.0.8)

winch_add_trace_back: Enrich an rlang traceback with details on native calls

Description

This function uses the native stack trace returned from winch_trace_back() to add details on native function calls to an rlang traceback object. It is intended to be called by rlang.

Usage

winch_add_trace_back(trace = rlang::trace_back(bottom = parent.frame()))

Arguments

trace

An rlang traceback as returned by rlang::trace_back().

Examples

Run this code
# NOT RUN {
foo <- function() {
  winch_call(bar)
}

bar <- function() {
  trace <- rlang::trace_back()
  winch_add_trace_back(trace)
}

foo()
# }

Run the code above in your browser using DataLab