mirror of
https://github.com/emilk/egui.git
synced 2026-08-30 13:20:05 -04:00
Improve documentation of eframe, especially for wasm32 (#3295)
* Improve documentation of `eframe`, especially for wasm32 * remove dead code * fix
This commit is contained in:
@@ -65,16 +65,19 @@ pub struct PanicSummary {
|
||||
}
|
||||
|
||||
impl PanicSummary {
|
||||
/// Construct a summary from a panic.
|
||||
pub fn new(info: &std::panic::PanicInfo<'_>) -> Self {
|
||||
let message = info.to_string();
|
||||
let callstack = Error::new().stack();
|
||||
Self { message, callstack }
|
||||
}
|
||||
|
||||
/// The panic message.
|
||||
pub fn message(&self) -> String {
|
||||
self.message.clone()
|
||||
}
|
||||
|
||||
/// The backtrace.
|
||||
pub fn callstack(&self) -> String {
|
||||
self.callstack.clone()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user