Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR RUST

debug rust

#[derive(Debug)]
struct Point {
    x: i32,
    y: i32,
}

let origin = Point { x: 0, y: 0 };

assert_eq!(format!("The origin is: {:?}", origin), "The origin is: Point { x: 0, y: 0 }");
Source by doc.rust-lang.org #
 
PREVIOUS NEXT
Tagged: #debug #rust
ADD COMMENT
Topic
Name
7+1 =