You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flex.apache.org by jm...@apache.org on 2017/06/11 02:29:59 UTC
git commit: [flex-falcon] [refs/heads/develop] - make it clear you
are not dividing by zero
Repository: flex-falcon
Updated Branches:
refs/heads/develop 16297c334 -> 7121b45a9
make it clear you are not dividing by zero
Project: http://git-wip-us.apache.org/repos/asf/flex-falcon/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-falcon/commit/7121b45a
Tree: http://git-wip-us.apache.org/repos/asf/flex-falcon/tree/7121b45a
Diff: http://git-wip-us.apache.org/repos/asf/flex-falcon/diff/7121b45a
Branch: refs/heads/develop
Commit: 7121b45a93588041bf6e099f33be448a4e3a5770
Parents: 16297c3
Author: Justin Mclean <jm...@apache.org>
Authored: Sun Jun 11 12:29:48 2017 +1000
Committer: Justin Mclean <jm...@apache.org>
Committed: Sun Jun 11 12:29:48 2017 +1000
----------------------------------------------------------------------
.../flex/compiler/internal/as/codegen/ABCGeneratingReducer.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/flex-falcon/blob/7121b45a/compiler/src/main/java/org/apache/flex/compiler/internal/as/codegen/ABCGeneratingReducer.java
----------------------------------------------------------------------
diff --git a/compiler/src/main/java/org/apache/flex/compiler/internal/as/codegen/ABCGeneratingReducer.java b/compiler/src/main/java/org/apache/flex/compiler/internal/as/codegen/ABCGeneratingReducer.java
index 776993f..c712f56 100644
--- a/compiler/src/main/java/org/apache/flex/compiler/internal/as/codegen/ABCGeneratingReducer.java
+++ b/compiler/src/main/java/org/apache/flex/compiler/internal/as/codegen/ABCGeneratingReducer.java
@@ -749,7 +749,7 @@ public class ABCGeneratingReducer
// java treats -0 and 0 as equal, but divide by -0 results in NEG INFINITY, whereas pos
// 0 results in POS INFINITY
// positive 0 can be encoded with a pushbyte, but neg zero requires a pushdouble
- if( dval == 0 && 1/dval == Double.NEGATIVE_INFINITY )
+ if( dval == 0.0 && 1.0/dval == Double.NEGATIVE_INFINITY )
result_list.addInstruction(OP_pushdouble, dval);
else
// Integer