File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ exclude = ["/js"]
1313[lib ]
1414crate-type = [" cdylib" , " rlib" ]
1515
16- [target . 'cfg(target_arch = "wasm32")' . dependencies ]
16+ [dependencies ]
1717wasm-bindgen = " 0.2"
1818
1919[dev-dependencies ]
Original file line number Diff line number Diff line change @@ -18,7 +18,6 @@ describe('StringOffsets sanity checks', () => {
1818 expect ( offsets . lines ( ) ) . toBe ( 2 ) ;
1919 // ☀️ is 6 UTF-8 bytes and 3 UTF-16 code units
2020 expect ( offsets . utf8_to_utf16 ( 6 ) ) . toBe ( 2 ) ;
21- // expect(offsets.utf16ToUtf8(3)).toBe(6);
2221 expect ( offsets . utf8_to_utf16 ( 0 ) ) . toBe ( 0 ) ;
2322 } ) ;
2423} ) ;
Original file line number Diff line number Diff line change @@ -148,6 +148,7 @@ impl StringOffsets {
148148 ///
149149 /// If `content` is UTF-8, this is just like [`StringOffsets::new`]. Otherwise, the
150150 /// conversion methods will produce unspecified (but memory-safe) results.
151+ #[ allow( unused_variables) ]
151152 #[ wasm_bindgen( static_method_of = StringOffsets ) ]
152153 pub fn from_bytes ( content : & [ u8 ] ) -> Self {
153154 new_converter ( content)
You can’t perform that action at this time.
0 commit comments