flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From erikdebr...@apache.org
Subject [3/7] git commit: [flex-asjs] [refs/heads/develop_strictest] - Fixed type checking issue when using '-strict' compiler setting.
Date Wed, 13 Nov 2013 10:44:58 GMT
Fixed type checking issue when using '-strict' compiler setting.

Signed-off-by: Erik de Bruin <erik@ixsoftware.nl>


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/d2211fc4
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/d2211fc4
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/d2211fc4

Branch: refs/heads/develop_strictest
Commit: d2211fc44c75a406ab3608347d88f1e1bc6d8a39
Parents: 4a5ca76
Author: Erik de Bruin <erik@ixsoftware.nl>
Authored: Wed Nov 13 09:30:43 2013 +0100
Committer: Erik de Bruin <erik@ixsoftware.nl>
Committed: Wed Nov 13 09:30:43 2013 +0100

----------------------------------------------------------------------
 .../js/FlexJS/src/org/apache/flex/utils/Language.js     | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/d2211fc4/frameworks/js/FlexJS/src/org/apache/flex/utils/Language.js
----------------------------------------------------------------------
diff --git a/frameworks/js/FlexJS/src/org/apache/flex/utils/Language.js b/frameworks/js/FlexJS/src/org/apache/flex/utils/Language.js
index 20c4634..3a610dc 100644
--- a/frameworks/js/FlexJS/src/org/apache/flex/utils/Language.js
+++ b/frameworks/js/FlexJS/src/org/apache/flex/utils/Language.js
@@ -27,11 +27,11 @@ org.apache.flex.utils.Language = function() {
  * as()
  *
  * @expose
- * @param {!Object} leftOperand The lefthand operand of the
+ * @param {*} leftOperand The lefthand operand of the
  *     binary as operator in AS3.
- * @param {!Object} rightOperand The righthand operand of the
+ * @param {*} rightOperand The righthand operand of the
  *     binary operator in AS3.
- * @return {?Object} Returns the lefthand operand if it is
+ * @return {*} Returns the lefthand operand if it is
  *     of the type of the righthand operand, otherwise null.
  */
 org.apache.flex.utils.Language.as = function(leftOperand, rightOperand) {
@@ -56,9 +56,9 @@ org.apache.flex.utils.Language._int = function(value) {
  * is()
  *
  * @expose
- * @param {?Object} leftOperand The lefthand operand of the
+ * @param {*} leftOperand The lefthand operand of the
  *     binary as operator in AS3.
- * @param {!Object} rightOperand The righthand operand of the
+ * @param {*} rightOperand The righthand operand of the
  *     binary operator in AS3.
  * @return {boolean}
  */
@@ -83,7 +83,7 @@ org.apache.flex.utils.Language.is = function(leftOperand, rightOperand)
{
     return false;
   };
 
-  if (leftOperand instanceof rightOperand) {
+  if (leftOperand instanceof /** @type {Object} */(rightOperand)) {
     return true;
   } else if (leftOperand.FLEXJS_CLASS_INFO &&
       leftOperand.FLEXJS_CLASS_INFO.interfaces) {


Mime
View raw message