@@ -2,7 +2,7 @@ use std::collections::HashMap;
22
33use cranelift:: prelude:: * ;
44use cranelift_module:: { DataContext , Linkage , Module } ;
5- use cranelift_simplejit:: { SimpleJITBackend , SimpleJITBuilder } ;
5+ use cranelift_simplejit:: { SimpleJITModule , SimpleJITBuilder } ;
66use frontend:: * ;
77use std:: slice;
88
@@ -22,14 +22,14 @@ pub struct JIT {
2222
2323 /// The module, with the simplejit backend, which manages the JIT'd
2424 /// functions.
25- module : Module < SimpleJITBackend > ,
25+ module : SimpleJITModule ,
2626}
2727
2828impl JIT {
2929 /// Create a new `JIT` instance.
3030 pub fn new ( ) -> Self {
3131 let builder = SimpleJITBuilder :: new ( cranelift_module:: default_libcall_names ( ) ) ;
32- let module = Module :: new ( builder) ;
32+ let module = SimpleJITModule :: new ( builder) ;
3333 Self {
3434 builder_context : FunctionBuilderContext :: new ( ) ,
3535 ctx : module. make_context ( ) ,
@@ -89,7 +89,7 @@ impl JIT {
8989 self . data_ctx . define ( contents. into_boxed_slice ( ) ) ;
9090 let id = self
9191 . module
92- . declare_data ( name, Linkage :: Export , true , false , None )
92+ . declare_data ( name, Linkage :: Export , true , false )
9393 . map_err ( |e| e. to_string ( ) ) ?;
9494
9595 self . module
@@ -178,7 +178,7 @@ struct FunctionTranslator<'a> {
178178 int : types:: Type ,
179179 builder : FunctionBuilder < ' a > ,
180180 variables : HashMap < String , Variable > ,
181- module : & ' a mut Module < SimpleJITBackend > ,
181+ module : & ' a mut SimpleJITModule ,
182182}
183183
184184impl < ' a > FunctionTranslator < ' a > {
@@ -374,7 +374,7 @@ impl<'a> FunctionTranslator<'a> {
374374 fn translate_global_data_addr ( & mut self , name : String ) -> Value {
375375 let sym = self
376376 . module
377- . declare_data ( & name, Linkage :: Export , true , false , None )
377+ . declare_data ( & name, Linkage :: Export , true , false )
378378 . expect ( "problem declaring data object" ) ;
379379 let local_id = self
380380 . module
0 commit comments