Nicolas Cannasse 18 rokov pred
rodič
commit
f051dd9dda

+ 2 - 2
std/haxe/Template.hx

@@ -288,7 +288,7 @@ class Template {
 		case "!":
 			var e = makeExpr(l);
 			return function() {
-				var v = e();
+				var v : Dynamic = e();
 				return (v == null || v == false);
 			};
 		case "-":
@@ -305,7 +305,7 @@ class Template {
 		case OpExpr(e):
 			buf.add(Std.string(e()));
 		case OpIf(e,eif,eelse):
-			var v = e();
+			var v : Dynamic = e();
 			if( v == null || v == false ) {
 				if( eelse != null ) run(eelse);
 			} else

+ 2 - 2
std/haxe/Timer.hx

@@ -26,7 +26,7 @@ package haxe;
 
 class Timer {
 
-	private var id : Int;
+	private var id : Null<Int>;
 
 	#if js
 	private static var arr = new Array<Timer>();
@@ -89,7 +89,7 @@ class Timer {
 		fqueue.push(f);
 		haxe.Timer.delayed(function() {
 			fqueue.shift()();
-		},if( time == null ) 0 else time)();
+		},#if !flash9 if( time == null ) 0 else #end time)();
 	}
 
 	#end

+ 2 - 2
std/haxe/remoting/SocketConnection.hx

@@ -73,7 +73,7 @@ class SocketConnection extends AsyncConnection {
 		#end
 	}
 
-	public static function decodeChar(c) {
+	public static function decodeChar(c) : Null<Int> {
 		// A...Z
 		if( c >= 65 && c <= 90 )
 			return c - 65;
@@ -92,7 +92,7 @@ class SocketConnection extends AsyncConnection {
 		return null;
 	}
 
-	public static function encodeChar(c) {
+	public static function encodeChar(c) : Null<Int> {
 		if( c < 0 )
 			return null;
 		// A...Z