Browse Source

Merge branch 'master' into v2.1

Mike Pall 12 years ago
parent
commit
55772e3ad9
1 changed files with 4 additions and 0 deletions
  1. 4 0
      src/lj_crecord.c

+ 4 - 0
src/lj_crecord.c

@@ -454,6 +454,10 @@ static TRef crec_ct_ct(jit_State *J, CType *d, CType *s, TRef dp, TRef sp,
     sinfo = CTINFO(CT_NUM, CTF_UNSIGNED);
     sinfo = CTINFO(CT_NUM, CTF_UNSIGNED);
     ssize = CTSIZE_PTR;
     ssize = CTSIZE_PTR;
     st = IRT_UINTP;
     st = IRT_UINTP;
+    if (((dsize ^ ssize) & 8) == 0) {  /* Must insert no-op type conversion. */
+      sp = emitconv(sp, dsize < 4 ? IRT_INT : dt, IRT_PTR, 0);
+      goto xstore;
+    }
     goto conv_I_I;
     goto conv_I_I;
 
 
   /* Destination is a floating-point number. */
   /* Destination is a floating-point number. */