@@ -101,7 +101,7 @@ fn foreign_signature(ccx: @CrateContext, fn_sig: &ty::FnSig)
101
101
LlvmSignature {
102
102
llarg_tys : llarg_tys,
103
103
llret_ty : llret_ty,
104
- sret : !ty:: type_is_immediate ( fn_sig. output ) ,
104
+ sret : !ty:: type_is_immediate ( ccx . tcx , fn_sig. output ) ,
105
105
}
106
106
}
107
107
@@ -193,7 +193,7 @@ fn build_wrap_fn_(ccx: @CrateContext,
193
193
194
194
// Patch up the return type if it's not immediate and we're returning via
195
195
// the C ABI.
196
- if needs_c_return && !ty:: type_is_immediate ( tys. fn_sig . output ) {
196
+ if needs_c_return && !ty:: type_is_immediate ( ccx . tcx , tys. fn_sig . output ) {
197
197
let lloutputtype = type_of:: type_of ( * fcx. ccx , tys. fn_sig . output ) ;
198
198
fcx. llretptr = Some ( alloca ( raw_block ( fcx, false , fcx. llstaticallocas ) ,
199
199
lloutputtype) ) ;
@@ -697,7 +697,7 @@ pub fn trans_intrinsic(ccx: @CrateContext,
697
697
// is not necessary since, for intrinsics, there is no
698
698
// cleanup to concern ourselves with.
699
699
let tp_ty = substs. tys [ 0 ] ;
700
- let mode = appropriate_mode ( tp_ty) ;
700
+ let mode = appropriate_mode ( ccx . tcx , tp_ty) ;
701
701
let src = Datum { val : get_param ( decl, first_real_arg + 1 u) ,
702
702
ty : tp_ty, mode : mode, source : RevokeClean } ;
703
703
bcx = src. move_to ( bcx, DROP_EXISTING ,
@@ -706,7 +706,7 @@ pub fn trans_intrinsic(ccx: @CrateContext,
706
706
~"move_val_init" => {
707
707
// See comments for `"move_val"`.
708
708
let tp_ty = substs. tys [ 0 ] ;
709
- let mode = appropriate_mode ( tp_ty) ;
709
+ let mode = appropriate_mode ( ccx . tcx , tp_ty) ;
710
710
let src = Datum { val : get_param ( decl, first_real_arg + 1 u) ,
711
711
ty : tp_ty, mode : mode, source : RevokeClean } ;
712
712
bcx = src. move_to ( bcx, INIT , get_param ( decl, first_real_arg) ) ;
@@ -777,7 +777,7 @@ pub fn trans_intrinsic(ccx: @CrateContext,
777
777
let lldestptr = PointerCast ( bcx, lldestptr, T_ptr ( T_i8 ( ) ) ) ;
778
778
779
779
let llsrcval = get_param ( decl, first_real_arg) ;
780
- let llsrcptr = if ty:: type_is_immediate ( in_type) {
780
+ let llsrcptr = if ty:: type_is_immediate ( ccx . tcx , in_type) {
781
781
let llsrcptr = alloca ( bcx, llintype) ;
782
782
Store ( bcx, llsrcval, llsrcptr) ;
783
783
llsrcptr
@@ -1228,7 +1228,7 @@ pub fn trans_foreign_fn(ccx: @CrateContext,
1228
1228
let mut i = 0 u;
1229
1229
let n = tys. fn_sig . inputs . len ( ) ;
1230
1230
1231
- if !ty:: type_is_immediate ( tys. fn_sig . output ) {
1231
+ if !ty:: type_is_immediate ( ccx . tcx , tys. fn_sig . output ) {
1232
1232
let llretptr = load_inbounds ( bcx, llargbundle, [ 0 u, n] ) ;
1233
1233
llargvals. push ( llretptr) ;
1234
1234
} else {
@@ -1256,7 +1256,7 @@ pub fn trans_foreign_fn(ccx: @CrateContext,
1256
1256
shim_types : & ShimTypes ,
1257
1257
llargbundle : ValueRef ,
1258
1258
llretval : ValueRef ) {
1259
- if ty:: type_is_immediate ( shim_types. fn_sig . output ) {
1259
+ if ty:: type_is_immediate ( bcx . tcx ( ) , shim_types. fn_sig . output ) {
1260
1260
// Write the value into the argument bundle.
1261
1261
let arg_count = shim_types. fn_sig . inputs . len ( ) ;
1262
1262
let llretptr = load_inbounds ( bcx,
0 commit comments