@@ -77,7 +77,7 @@ impl<'vm, F> Pushable<'vm> for Primitive<F>
7777where
7878 F : FunctionType + VmType ,
7979{
80- fn push ( self , context : & mut ActiveThread < ' vm > ) -> Result < ( ) > {
80+ fn vm_push ( self , context : & mut ActiveThread < ' vm > ) -> Result < ( ) > {
8181 // Map rust modules into gluon modules
8282 let name = if let Some ( i) = self . name . rfind ( "::<" ) {
8383 & self . name [ ..i]
@@ -111,7 +111,7 @@ impl CPrimitive {
111111}
112112
113113impl < ' vm > Pushable < ' vm > for CPrimitive {
114- fn push ( self , context : & mut ActiveThread < ' vm > ) -> Result < ( ) > {
114+ fn vm_push ( self , context : & mut ActiveThread < ' vm > ) -> Result < ( ) > {
115115 context. context ( ) . push_new_alloc ( Move ( ExternFunction {
116116 id : self . id ,
117117 args : self . args ,
@@ -196,7 +196,7 @@ where
196196 T : VmRootInternal ,
197197 F : VmType ,
198198{
199- fn push ( self , context : & mut ActiveThread < ' vm > ) -> Result < ( ) > {
199+ fn vm_push ( self , context : & mut ActiveThread < ' vm > ) -> Result < ( ) > {
200200 context. push ( self . value . get_variant ( ) ) ;
201201 Ok ( ( ) )
202202 }
@@ -292,7 +292,7 @@ where $($args: Getable<'vm, 'vm> + 'vm,)*
292292 Ok ( x) => x,
293293 Err ( err) => {
294294 drop( stack) ;
295- err. to_string( ) . push ( & mut context) . unwrap( ) ;
295+ err. to_string( ) . vm_push ( & mut context) . unwrap( ) ;
296296 return Status :: Error ;
297297 }
298298 } ;
@@ -398,10 +398,10 @@ impl<T, $($args,)* R> Function<T, fn($($args),*) -> R>
398398 let mut context = vm. current_context( ) ;
399399 context. push( self . value. get_variant( ) ) ;
400400 $(
401- $args. push ( & mut context) ?;
401+ $args. vm_push ( & mut context) ?;
402402 ) *
403403 for _ in 0 ..R :: EXTRA_ARGS {
404- 0 . push ( & mut context) . unwrap( ) ;
404+ 0 . vm_push ( & mut context) . unwrap( ) ;
405405 }
406406 let args = count!( $( $args) ,* ) + R :: EXTRA_ARGS ;
407407 let context = ready!( vm. call_function( cx, context. into_owned( ) , args) ) ?;
@@ -510,10 +510,10 @@ where
510510 let mut arg_count = R :: EXTRA_ARGS ;
511511 for arg in args {
512512 arg_count += 1 ;
513- arg. push ( & mut context) ?;
513+ arg. vm_push ( & mut context) ?;
514514 }
515515 for _ in 0 ..R :: EXTRA_ARGS {
516- 0 . push ( & mut context) . unwrap ( ) ;
516+ 0 . vm_push ( & mut context) . unwrap ( ) ;
517517 }
518518 let context = ready ! ( vm. call_function( cx, context. into_owned( ) , arg_count) ) ?;
519519 let mut context = context. unwrap ( ) ;
@@ -562,7 +562,7 @@ impl<T: VmType> VmType for TypedBytecode<T> {
562562}
563563
564564impl < ' vm , T : VmType > Pushable < ' vm > for TypedBytecode < T > {
565- fn push ( self , context : & mut ActiveThread < ' vm > ) -> Result < ( ) > {
565+ fn vm_push ( self , context : & mut ActiveThread < ' vm > ) -> Result < ( ) > {
566566 let closure = {
567567 let thread = context. thread ( ) ;
568568 let mut compiled_module = CompiledModule :: from ( CompiledFunction :: new (
@@ -576,6 +576,6 @@ impl<'vm, T: VmType> Pushable<'vm> for TypedBytecode<T> {
576576 . global_env ( )
577577 . new_global_thunk ( thread, compiled_module) ?
578578 } ;
579- closure. push ( context)
579+ closure. vm_push ( context)
580580 }
581581}
0 commit comments