fix mono test

This commit is contained in:
Folkert 2020-11-14 02:58:12 +01:00
parent 154b5cc29f
commit 0dde6da77d
2 changed files with 5 additions and 1 deletions

View file

@ -765,7 +765,7 @@ pub fn build_exp_expr<'a, 'ctx, 'env>(
field_types.push(field_type);
if let Layout::RecursivePointer = tag_field_layout {
let ptr = allocate_with_refcount(env, &tag_layout, val).into();
let ptr = allocate_with_refcount(env, &tag_layout, val);
builder.build_store(ptr, val);

View file

@ -1850,6 +1850,7 @@ mod test_mono {
let Test.2 = S Test.8 Test.9;
let Test.5 = 1i64;
let Test.6 = Index 0 Test.2;
dec Test.2;
let Test.7 = lowlevel Eq Test.5 Test.6;
if Test.7 then
let Test.3 = 0i64;
@ -1901,12 +1902,15 @@ mod test_mono {
let Test.10 = lowlevel Eq Test.8 Test.9;
if Test.10 then
let Test.4 = Index 1 Test.2;
dec Test.2;
let Test.3 = 1i64;
ret Test.3;
else
dec Test.2;
let Test.5 = 0i64;
ret Test.5;
else
dec Test.2;
let Test.6 = 0i64;
ret Test.6;
"#