File tree Expand file tree Collapse file tree 1 file changed +7
-14
lines changed Expand file tree Collapse file tree 1 file changed +7
-14
lines changed Original file line number Diff line number Diff line change 6
6
struct A ;
7
7
8
8
impl A {
9
- fn result_with_debug_assert_with_message ( x : i32 ) -> Result < bool , String >
10
- {
9
+ fn result_with_debug_assert_with_message ( x : i32 ) -> Result < bool , String > {
11
10
debug_assert ! ( x == 5 , "wrong argument" ) ;
12
11
Ok ( true )
13
12
}
14
13
15
- fn result_with_debug_assert_eq ( x : i32 ) -> Result < bool , String >
16
- {
14
+ fn result_with_debug_assert_eq ( x : i32 ) -> Result < bool , String > {
17
15
debug_assert_eq ! ( x, 5 ) ;
18
16
Ok ( true )
19
17
}
20
18
21
- fn result_with_debug_assert_ne ( x : i32 ) -> Result < bool , String >
22
- {
19
+ fn result_with_debug_assert_ne ( x : i32 ) -> Result < bool , String > {
23
20
debug_assert_ne ! ( x, 1 ) ;
24
21
Ok ( true )
25
22
}
26
23
27
- fn other_with_debug_assert_with_message ( x : i32 )
28
- {
24
+ fn other_with_debug_assert_with_message ( x : i32 ) {
29
25
debug_assert ! ( x == 5 , "wrong argument" ) ;
30
26
}
31
27
32
- fn other_with_debug_assert_eq ( x : i32 )
33
- {
28
+ fn other_with_debug_assert_eq ( x : i32 ) {
34
29
debug_assert_eq ! ( x, 5 ) ;
35
30
}
36
31
37
- fn other_with_debug_assert_ne ( x : i32 )
38
- {
32
+ fn other_with_debug_assert_ne ( x : i32 ) {
39
33
debug_assert_ne ! ( x, 1 ) ;
40
34
}
41
35
42
- fn result_without_banned_functions ( ) -> Result < bool , String >
43
- {
36
+ fn result_without_banned_functions ( ) -> Result < bool , String > {
44
37
let debug_assert = "debug_assert!" ;
45
38
println ! ( "No {}" , debug_assert) ;
46
39
Ok ( true )
You can’t perform that action at this time.
0 commit comments