2
0
Эх сурвалжийг харах

* fixed range error in case node distance calculation

git-svn-id: trunk@9662 -
Jonas Maebe 17 жил өмнө
parent
commit
03e9f652fd

+ 4 - 1
compiler/ncgset.pas

@@ -767,7 +767,10 @@ implementation
                      distv:=max_label+min_label
                      distv:=max_label+min_label
                    else
                    else
                      distv:=max_label-min_label;
                      distv:=max_label-min_label;
-                   dist:=distv.uvalue;
+                   if (distv>=0) then
+                     dist:=distv.uvalue
+                   else
+                     dist:=-distv.svalue;
 
 
                    { optimize for size ? }
                    { optimize for size ? }
                    if cs_opt_size in current_settings.optimizerswitches  then
                    if cs_opt_size in current_settings.optimizerswitches  then