diff --git a/compiler/ninl.pas b/compiler/ninl.pas index 9f26cc6ba2..3298248bc0 100644 --- a/compiler/ninl.pas +++ b/compiler/ninl.pas @@ -1060,7 +1060,8 @@ implementation if assigned(orgcode) then addstatement(newstatement,cassignmentnode.create( orgcode, - ctemprefnode.create(tempcode))); + ctypeconvnode.create_internal( + ctemprefnode.create(tempcode),orgcode.resulttype))); { release the temp if we allocated one } if assigned(tempcode) then