pub struct DebugWhat {
pub using_function: bool,
/* private fields */
}Expand description
Structure for defining what information needs to be extracted from a function.
This is used in lua_getinfo and
ThreadDebug::get_info.
Fields§
§using_function: boolUse a function from the stack instead of an activation record.
Implementations§
Source§impl DebugWhat
impl DebugWhat
Sourcepub fn write_string<'a>(&self, buffer: &'a mut [u8]) -> &'a CStr
pub fn write_string<'a>(&self, buffer: &'a mut [u8]) -> &'a CStr
Write out a “what” string into buffer and return the slice that
contains it.
The maximum number of C characters that can be written to buffer is
10, including the zero-terminator.
Sourcepub const fn with_current_line(self) -> Self
pub const fn with_current_line(self) -> Self
Require current line (current_line).
Sourcepub const fn with_transfer_info(self) -> Self
pub const fn with_transfer_info(self) -> Self
Require transfer information (first_transferred, n_transferred).
Sourcepub const fn with_source_info(self) -> Self
pub const fn with_source_info(self) -> Self
Require source information (source, source_len, short_src,
line_defined, last_line_defined, what).
Sourcepub const fn with_tail_call_info(self) -> Self
pub const fn with_tail_call_info(self) -> Self
Require tall call information (is_tail_call).
Sourcepub const fn with_prototype(self) -> Self
pub const fn with_prototype(self) -> Self
Require function prototype information (n_upvalues, n_params,
is_vararg).
Sourcepub const fn with_lines(self) -> Self
pub const fn with_lines(self) -> Self
Require source code lines (push table of them onto the stack).