@@ -13,7 +13,7 @@ use super::{UnicodeWidthChar, UnicodeWidthStr};
13
13
#[ cfg( feature = "bench" ) ]
14
14
use std:: iter;
15
15
#[ cfg( feature = "bench" ) ]
16
- use test:: { self , Bencher } ;
16
+ use test:: Bencher ;
17
17
18
18
use std:: prelude:: v1:: * ;
19
19
@@ -140,8 +140,6 @@ fn test_emoji() {
140
140
#[ test]
141
141
fn test_char ( ) {
142
142
use super :: UnicodeWidthChar ;
143
- #[ cfg( feature = "no_std" ) ]
144
- use core:: option:: Option :: { None , Some } ;
145
143
146
144
assert_eq ! ( UnicodeWidthChar :: width( 'h' ) , Some ( 2 ) ) ;
147
145
assert_eq ! ( 'h' . width_cjk( ) , Some ( 2 ) ) ;
@@ -156,8 +154,6 @@ fn test_char() {
156
154
#[ test]
157
155
fn test_char2 ( ) {
158
156
use super :: UnicodeWidthChar ;
159
- #[ cfg( feature = "no_std" ) ]
160
- use core:: option:: Option :: { None , Some } ;
161
157
162
158
assert_eq ! ( UnicodeWidthChar :: width( '\x00' ) , Some ( 0 ) ) ;
163
159
assert_eq ! ( '\x00' . width_cjk( ) , Some ( 0 ) ) ;
@@ -187,17 +183,13 @@ fn test_char2() {
187
183
#[ test]
188
184
fn unicode_12 ( ) {
189
185
use super :: UnicodeWidthChar ;
190
- #[ cfg( feature = "no_std" ) ]
191
- use core:: option:: Option :: { None , Some } ;
192
186
193
187
assert_eq ! ( UnicodeWidthChar :: width( '\u{1F971}' ) , Some ( 2 ) ) ;
194
188
}
195
189
196
190
#[ test]
197
191
fn test_default_ignorable ( ) {
198
192
use super :: UnicodeWidthChar ;
199
- #[ cfg( feature = "no_std" ) ]
200
- use core:: option:: Option :: { None , Some } ;
201
193
202
194
assert_eq ! ( UnicodeWidthChar :: width( '\u{E0000}' ) , Some ( 0 ) ) ;
203
195
@@ -209,8 +201,6 @@ fn test_default_ignorable() {
209
201
#[ test]
210
202
fn test_jamo ( ) {
211
203
use super :: UnicodeWidthChar ;
212
- #[ cfg( feature = "no_std" ) ]
213
- use core:: option:: Option :: { None , Some } ;
214
204
215
205
assert_eq ! ( UnicodeWidthChar :: width( '\u{1100}' ) , Some ( 2 ) ) ;
216
206
assert_eq ! ( UnicodeWidthChar :: width( '\u{A97C}' ) , Some ( 2 ) ) ;
@@ -225,8 +215,6 @@ fn test_jamo() {
225
215
#[ test]
226
216
fn test_prepended_concatenation_marks ( ) {
227
217
use super :: UnicodeWidthChar ;
228
- #[ cfg( feature = "no_std" ) ]
229
- use core:: option:: Option :: { None , Some } ;
230
218
231
219
assert_eq ! ( UnicodeWidthChar :: width( '\u{0600}' ) , Some ( 1 ) ) ;
232
220
assert_eq ! ( UnicodeWidthChar :: width( '\u{070F}' ) , Some ( 1 ) ) ;
@@ -237,8 +225,6 @@ fn test_prepended_concatenation_marks() {
237
225
#[ test]
238
226
fn test_interlinear_annotation_chars ( ) {
239
227
use super :: UnicodeWidthChar ;
240
- #[ cfg( feature = "no_std" ) ]
241
- use core:: option:: Option :: { None , Some } ;
242
228
243
229
assert_eq ! ( UnicodeWidthChar :: width( '\u{FFF9}' ) , Some ( 1 ) ) ;
244
230
assert_eq ! ( UnicodeWidthChar :: width( '\u{FFFA}' ) , Some ( 1 ) ) ;
@@ -248,8 +234,6 @@ fn test_interlinear_annotation_chars() {
248
234
#[ test]
249
235
fn test_hieroglyph_format_controls ( ) {
250
236
use super :: UnicodeWidthChar ;
251
- #[ cfg( feature = "no_std" ) ]
252
- use core:: option:: Option :: { None , Some } ;
253
237
254
238
assert_eq ! ( UnicodeWidthChar :: width( '\u{13430}' ) , Some ( 1 ) ) ;
255
239
assert_eq ! ( UnicodeWidthChar :: width( '\u{13436}' ) , Some ( 1 ) ) ;
0 commit comments