-
Notifications
You must be signed in to change notification settings - Fork 115
new_tracepoint
wpferguson edited this page Jun 14, 2020
·
1 revision
new_tracepoint
create a function returning a tracepoint
local dd = require "lib/dtutils.debug"
local result = new_tracepoint(name, ...)
name - string - the name of the tracepoint to print out
... - arguments - variables to dump the contents of
new_tracepoint returns a tracepoint function with the given name. This is mainly used to debug callbacks.
result - function - a function that returns the result of a tracepoint
register_event(event, dd.new_tracepoint("hit callback"))
will print the following each time the callback is called
**** hit callback ****
<all the callback's parameters dumped>