File tree Expand file tree Collapse file tree 4 files changed +4
-5
lines changed Expand file tree Collapse file tree 4 files changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -467,7 +467,7 @@ impl AtomTable {
467467 }
468468
469469 pub fn build_with ( atom_table : & AtomTable , string : & str ) -> Atom {
470- if 0 < string. len ( ) && string. len ( ) <= INLINED_ATOM_MAX_LEN {
470+ if 0 < string. len ( ) && string. len ( ) <= INLINED_ATOM_MAX_LEN && !string . contains ( '\u{0}' ) {
471471 return Atom :: new_inlined ( string) ;
472472 }
473473
Original file line number Diff line number Diff line change 177177
178178filter_anonymous_vars ([] , [] ).
179179filter_anonymous_vars ([VN =V | VNEqs0 ], VNEqs ) :-
180- '$debug_hook' ,
181180 ( atom_concat('_' , _ , VN ) ->
182181 filter_anonymous_vars (VNEqs0 , VNEqs )
183182 ; VNEqs = [VN =V | VNEqs1 ],
Original file line number Diff line number Diff line change @@ -101,7 +101,8 @@ impl ConsPtr {
101101
102102 #[ inline( always) ]
103103 pub fn as_ptr ( self ) -> * mut u8 {
104- unsafe { mem:: transmute :: < _ , * mut u8 > ( self . ptr ( ) ) }
104+ let addr: u64 = self . ptr ( ) ;
105+ addr as usize as * mut _
105106 }
106107
107108 #[ inline( always) ]
Original file line number Diff line number Diff line change 761761
762762test_229 :- test_syntax_error("\" \\z . \"", syntax_error(missing_quote )).
763763
764- test_300 :- '$debug_hook' ,
765- writeq_term_to_chars("\0\" , C ),
764+ test_300 :- writeq_term_to_chars("\0\" , C ),
766765 C == "['\\x0\\']" .
767766
768767test_172 :- X is 10 . 0** -323,
You can’t perform that action at this time.
0 commit comments