File tree Expand file tree Collapse file tree 3 files changed +5
-8
lines changed Expand file tree Collapse file tree 3 files changed +5
-8
lines changed Original file line number Diff line number Diff line change 1010#![ crate_name="string_cache_plugin" ]
1111#![ crate_type="dylib" ]
1212
13- #![ feature( plugin_registrar, quote, box_syntax, static_assert ) ]
13+ #![ feature( plugin_registrar, quote, box_syntax) ]
1414#![ feature( rustc_private, slice_patterns) ]
1515#![ deny( warnings) ]
1616#![ allow( unused_imports) ] // for quotes
Original file line number Diff line number Diff line change 1111//! the macros crate and the run-time library, in order to guarantee
1212//! consistency.
1313
14- #![ feature( core, static_assert ) ]
14+ #![ feature( core) ]
1515#![ deny( warnings) ]
1616
1717use std:: { mem, raw, intrinsics} ;
@@ -42,11 +42,9 @@ pub enum UnpackedAtom {
4242
4343const STATIC_SHIFT_BITS : usize = 32 ;
4444
45+ #[ cfg( target_endian = "little" ) ] // Not implemented yet for big-endian
4546#[ inline( always) ]
4647unsafe fn inline_atom_slice ( x : & u64 ) -> raw:: Slice < u8 > {
47- #[ static_assert]
48- const _IS_LITTLE_ENDIAN: bool = cfg ! ( target_endian = "little" ) ;
49-
5048 let x: * const u64 = x;
5149 raw:: Slice {
5250 data : ( x as * const u8 ) . offset ( 1 ) ,
@@ -82,8 +80,7 @@ impl UnpackedAtom {
8280
8381 #[ inline( always) ]
8482 pub unsafe fn from_packed ( data : u64 ) -> UnpackedAtom {
85- #[ static_assert]
86- const _DYNAMIC_IS_UNTAGGED: bool = DYNAMIC_TAG == 0 ;
83+ debug_assert ! ( DYNAMIC_TAG == 0 ) ; // Dynamic is untagged
8784
8885 match ( data & 0xf ) as u8 {
8986 DYNAMIC_TAG => Dynamic ( data as * mut ( ) ) ,
Original file line number Diff line number Diff line change 1010#![ crate_name = "string_cache" ]
1111#![ crate_type = "rlib" ]
1212
13- #![ feature( plugin, unsafe_no_drop_flag, static_assert ) ]
13+ #![ feature( plugin, unsafe_no_drop_flag) ]
1414#![ feature( core, collections, alloc, hash) ]
1515#![ deny( warnings) ]
1616#![ cfg_attr( test, feature( test) ) ]
You can’t perform that action at this time.
0 commit comments