瀏覽代碼

is Dynamic.

Nicolas Cannasse 19 年之前
父節點
當前提交
84ecd6afc1
共有 3 個文件被更改,包括 9 次插入2 次删除
  1. 2 0
      std/flash/Boot.hx
  2. 2 0
      std/js/Boot.hx
  3. 5 2
      std/neko/Boot.hx

+ 2 - 0
std/flash/Boot.hx

@@ -106,6 +106,8 @@ class Boot {
 				return (o == true || o == false);
 			case String:
 				return __typeof__(o) == "string";
+			case Dynamic:
+				return true;
 			default:
 				return false;
 			}

+ 2 - 0
std/js/Boot.hx

@@ -147,6 +147,8 @@ class Boot {
 				return (o === true || o === false);
 			case String:
 				return __js__("typeof(o)") == "string";
+			case Dynamic:
+				return true;
 			default:
 				return false;
 			}

+ 5 - 2
std/neko/Boot.hx

@@ -29,6 +29,8 @@ class Boot {
 
 	private static function __instanceof(o,cl) {
 		untyped {
+			if( cl == Dynamic )
+				return true;
 			switch __dollar__typeof(o) {
 			case __dollar__tint: return (cl == Int || cl == Float);
 			case __dollar__tfloat: return cl == Float;
@@ -64,8 +66,9 @@ class Boot {
 			Date = NekoDate__;
 			Int = __dollar__new(null);
 			Float = __dollar__new(null);
-			Bool.true = true;
-			Bool.false = false;
+			Bool = __dollar__new(null);
+			__dollar__objset(Bool,__dollar__hash("true".__s),true);
+			__dollar__objset(Bool,__dollar__hash("false".__s),false);
 		}
 	}