aide/features/rs_files/
expand_struct_string.rs

1
2
3pub const STRUCT_STRING_OK :&str = r#"#![allow(unused_variables)]
4pub fn main() {
5    #[derive(Clone)]
6    struct Struct(String);
7    let instance = Struct(String::from("Hello"));
8    let clone_instance = instance.clone();
9    let copy_instance = instance;
10    let use_copy_instance = copy_instance;
11}
12"#;
13
14pub const STRUCT_STRING_ERR_04 :&str = r#"#![allow(unused_variables)]
15pub fn main() {
16    #[derive(Clone, Copy)]
17    struct Struct(String);
18    let instance = Struct(String::from("Hello"));
19    let clone_instance = instance.clone();
20    let copy_instance = instance;
21    let use_instance = instance;
22}
23"#;
24
25pub const STRUCT_STRING_ERR_05 :&str = r#"#![allow(unused_variables)]
26pub fn main() {
27    #[derive(Clone)]
28    struct Struct(String);
29    let instance = Struct(String::from("Hello"));
30    let clone_instance = instance.clone();
31    let copy_instance = instance;
32    let use_instance = instance;
33}
34"#;
35
36pub const STRUCT_STRING_ERR_06 :&str = r#"#![allow(unused_variables)]
37pub fn main() {
38    #[derive(Copy)]
39    struct Struct(String);
40    let instance = Struct(String::from("Hello"));
41    let clone_instance = instance.clone();
42    let copy_instance = instance;
43    let use_instance = instance;
44}
45"#;