This commit is contained in:
parent
673e3882c9
commit
aaa04cdb16
|
|
@ -10900,7 +10900,6 @@ namespace PascalABCCompiler.NETGenerator
|
|||
il.Emit(OpCodes.Br, EndLabel);
|
||||
il.MarkLabel(NullLabel);
|
||||
value.ret_if_null.visit(this);
|
||||
ti = helper.GetTypeReference(value.ret_if_null.type);
|
||||
if (ti != null)
|
||||
EmitBox(value.ret_if_null, ti.tp);
|
||||
il.MarkLabel(EndLabel);
|
||||
|
|
|
|||
11
TestSuite/double_question5.pas
Normal file
11
TestSuite/double_question5.pas
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
var i: integer;
|
||||
procedure test(o: object);
|
||||
begin
|
||||
i := integer(o);
|
||||
end;
|
||||
begin
|
||||
var x: Object := nil;
|
||||
var y:= x ?? 10;
|
||||
test(y);
|
||||
assert(i = 10);
|
||||
end.
|
||||
|
|
@ -18580,7 +18580,6 @@ namespace PascalABCCompiler.TreeConverter
|
|||
{
|
||||
right = convertion_data_and_alghoritms.convert_type(right, left.type);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue