@@ -65,7 +65,7 @@ pub fn increment_bytes(cr: &mut OCamlRuntime, bytes: &str, first_n: usize) -> St
65
65
ocaml_frame ! ( cr, ( bytes_root, first_n_root) , {
66
66
let bytes = to_ocaml!( cr, bytes, bytes_root) ;
67
67
let first_n = to_ocaml!( cr, first_n as i64 , first_n_root) ;
68
- let result = ocaml:: increment_bytes( cr, & bytes, & first_n) . unwrap ( ) ;
68
+ let result = ocaml:: increment_bytes( cr, & bytes, & first_n) ;
69
69
result. to_rust( )
70
70
} )
71
71
}
@@ -74,8 +74,6 @@ pub fn increment_ints_list(cr: &mut OCamlRuntime, ints: &Vec<i64>) -> Vec<i64> {
74
74
ocaml_frame ! ( cr, ( root) , {
75
75
let ints = to_ocaml!( cr, ints, root) ;
76
76
let result = ocaml:: increment_ints_list( cr, & ints) ;
77
- let result: OCaml <OCamlList <OCamlInt >> =
78
- result. expect( "Error in 'increment_ints_list' call result" ) ;
79
77
result. to_rust( )
80
78
} )
81
79
}
@@ -85,7 +83,6 @@ pub fn twice(cr: &mut OCamlRuntime, num: i64) -> i64 {
85
83
let num = unsafe { OCaml :: of_i64_unchecked( num) } ;
86
84
let num = root. keep( num) ;
87
85
let result = ocaml:: twice( cr, & num) ;
88
- let result: OCaml <OCamlInt > = result. expect( "Error in 'twice' call result" ) ;
89
86
result. to_rust( )
90
87
} )
91
88
}
@@ -96,7 +93,6 @@ pub fn make_tuple(cr: &mut OCamlRuntime, fst: String, snd: i64) -> (String, i64)
96
93
let num = num_root. keep( num) ;
97
94
let str = to_ocaml!( cr, fst, str_root) ;
98
95
let result = ocaml:: make_tuple( cr, & str , & num) ;
99
- let result: OCaml <( String , OCamlInt ) > = result. expect( "Error in 'make_tuple' call result" ) ;
100
96
result. to_rust( )
101
97
} )
102
98
}
@@ -105,7 +101,6 @@ pub fn make_some(cr: &mut OCamlRuntime, value: String) -> Option<String> {
105
101
ocaml_frame ! ( cr, ( root) , {
106
102
let str = to_ocaml!( cr, value, root) ;
107
103
let result = ocaml:: make_some( cr, & str ) ;
108
- let result: OCaml <Option <String >> = result. expect( "Error in 'make_some' call result" ) ;
109
104
result. to_rust( )
110
105
} )
111
106
}
@@ -114,8 +109,6 @@ pub fn make_ok(cr: &mut OCamlRuntime, value: i64) -> Result<i64, String> {
114
109
ocaml_frame ! ( cr, ( root) , {
115
110
let result = to_ocaml!( cr, value, root) ;
116
111
let result = ocaml:: make_ok( cr, & result) ;
117
- let result: OCaml <Result <OCamlInt , String >> =
118
- result. expect( "Error in 'make_ok' call result" ) ;
119
112
result. to_rust( )
120
113
} )
121
114
}
@@ -124,8 +117,6 @@ pub fn make_error(cr: &mut OCamlRuntime, value: String) -> Result<i64, String> {
124
117
ocaml_frame ! ( cr, ( root) , {
125
118
let result = to_ocaml!( cr, value, root) ;
126
119
let result = ocaml:: make_error( cr, & result) ;
127
- let result: OCaml <Result <OCamlInt , String >> =
128
- result. expect( "Error in 'make_error' call result" ) ;
129
120
result. to_rust( )
130
121
} )
131
122
}
@@ -134,7 +125,6 @@ pub fn verify_record_test(cr: &mut OCamlRuntime, record: ocaml::TestRecord) -> S
134
125
ocaml_frame ! ( cr, ( root) , {
135
126
let ocaml_record = to_ocaml!( cr, record, root) ;
136
127
let result = ocaml:: stringify_record( cr, & ocaml_record) ;
137
- let result: OCaml <String > = result. expect( "Error in 'stringify_record' call result" ) ;
138
128
result. to_rust( )
139
129
} )
140
130
}
@@ -143,7 +133,6 @@ pub fn verify_variant_test(cr: &mut OCamlRuntime, variant: ocaml::Movement) -> S
143
133
ocaml_frame ! ( cr, ( root) , {
144
134
let ocaml_variant = to_ocaml!( cr, variant, root) ;
145
135
let result = ocaml:: stringify_variant( cr, & ocaml_variant) ;
146
- let result: OCaml <String > = result. expect( "Error in 'stringify_variant' call result" ) ;
147
136
result. to_rust( )
148
137
} )
149
138
}
0 commit comments