From a1ccab5e2330d0ef457aa6bc77bd76555ab411cd Mon Sep 17 00:00:00 2001 From: nickysn Date: Thu, 23 Apr 2020 00:06:03 +0000 Subject: [PATCH] + handle properly ret in param in tinlinenode.first_abs_real git-svn-id: branches/z80@45012 - --- compiler/ninl.pas | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/compiler/ninl.pas b/compiler/ninl.pas index 5ca4a1e18f..695bf85386 100644 --- a/compiler/ninl.pas +++ b/compiler/ninl.pas @@ -4172,14 +4172,19 @@ implementation function tinlinenode.first_abs_real : tnode; var callnode : tcallnode; + temp_pnode: pnode; begin { create the call to the helper } { on entry left node contains the parameter } + if left.nodetype = callparan then + temp_pnode := @tcallparanode(left).left + else + temp_pnode := @left; callnode:=ccallnode.createintern('fpc_abs_real', - ccallparanode.create(left,nil)); + ccallparanode.create(temp_pnode^,nil)); result := ctypeconvnode.create(callnode,resultdef); include(callnode.callnodeflags,cnf_check_fpu_exceptions); - left := nil; + temp_pnode^ := nil; end; function tinlinenode.first_sqr_real : tnode;