Nicolas Cannasse 19 years ago
parent
commit
e1e3dab24d
2 changed files with 3 additions and 3 deletions
  1. 2 2
      genswf8.ml
  2. 1 1
      std/Hash.hx

+ 2 - 2
genswf8.ml

@@ -168,7 +168,7 @@ let new_call ctx kind n  =
 	ctx.stack_size <- ctx.stack_size - n
 
 let always_protected = function
-	| "prototype" | "toString" | "__resolve" | "__constructor__" | "__proto__" -> true
+	| "prototype" | "toString" | "__resolve" | "__constructor__" | "__proto__" | "iterator" -> true
 	(*// haxe.PosInfos *)
 	| "fileName" | "lineNumber" | "className" | "methodName" | "customParams" -> true
 	| s ->
@@ -198,7 +198,7 @@ let rec is_protected ctx t check_mt =
 		loop c
 	| TMono r ->
 		(match !r with
-		| None -> true
+		| None -> assert false
 		| Some t -> is_protected ctx t check_mt)
 	| TLazy f ->
 		is_protected ctx ((!f)()) check_mt

+ 1 - 1
std/Hash.hx

@@ -114,7 +114,7 @@ class Hash<T> {
 	**/
 	public function keys() : Iterator<String> {
 		#if flash
-		return untyped (__keys__(h)).iterator();
+		return untyped (__keys__(h))["iterator"]();
 		#else js
 		return Reflect.fields(h).iterator();
 		#else neko