Browse Source

* Also merge 39991 to avoid wrong typecast in first_sqrt_real

------------------------------------------------------------------------
r39991 | florian | 2018-10-20 10:18:45 +0000 (Sat, 20 Oct 2018) | 2 lines

* same fix as in r39988 for fpc_first_sqrt

------------------------------------------------------------------------
--- Merging r39991 into '.':
U    compiler/ninl.pas
--- Recording mergeinfo for merge of r39991 into '.':
 U   .

git-svn-id: branches/fixes_3_2@46285 -
pierre 5 years ago
parent
commit
4ba3bfb227
1 changed files with 5 additions and 3 deletions
  1. 5 3
      compiler/ninl.pas

+ 5 - 3
compiler/ninl.pas

@@ -4102,6 +4102,7 @@ implementation
       var
         fdef: tdef;
         procname: string[31];
+        callnode: tcallnode;
       begin
         if ((cs_fp_emulation in current_settings.moduleswitches)
 {$ifdef cpufpemu}
@@ -4133,9 +4134,10 @@ implementation
           begin
             { create the call to the helper }
             { on entry left node contains the parameter }
-            result := ctypeconvnode.create(ccallnode.createintern('fpc_sqrt_real',
-                ccallparanode.create(left,nil)),resultdef);
-            include(tcallnode(result).callnodeflags,cnf_check_fpu_exceptions);
+            callnode := ccallnode.createintern('fpc_sqrt_real',
+                ccallparanode.create(left,nil));
+            result := ctypeconvnode.create(callnode,resultdef);
+            include(callnode.callnodeflags,cnf_check_fpu_exceptions);
           end;
         left := nil;
       end;