Procházet zdrojové kódy

apparently we enforce var name equality

Simon Krajewski před 12 roky
rodič
revize
efc015dfdb

+ 5 - 5
std/cpp/_std/sys/FileSystem.hx

@@ -34,9 +34,9 @@ class FileSystem {
 		return sys_exists(path);
 	}
 
-	public static function rename( path : String, newpath : String ) : Void {
-		if (sys_rename(path,newpath)==null)
-         throw "Could not rename:" + path + " to " + newpath;
+	public static function rename( path : String, newPath : String ) : Void {
+		if (sys_rename(path,newPath)==null)
+         throw "Could not rename:" + path + " to " + newPath;
 	}
 
 	public static function stat( path : String ) : FileStat {
@@ -49,8 +49,8 @@ class FileSystem {
 		return s;
 	}
 
-	public static function fullPath( relpath : String ) : String {
-		return new String(file_full_path(relpath));
+	public static function fullPath( relPath : String ) : String {
+		return new String(file_full_path(relPath));
 	}
 
 	static function kind( path : String ) : FileKind {

+ 3 - 3
std/cpp/_std/sys/io/File.hx

@@ -58,9 +58,9 @@ class File {
 		return untyped new FileOutput(file_open(path,(if( binary ) "ab" else "a")));
 	}
 
-	public static function copy( src : String, dst : String ) : Void {
-		var s = read(src,true);
-		var d = write(dst,true);
+	public static function copy( srcPath : String, dstPath : String ) : Void {
+		var s = read(srcPath,true);
+		var d = write(dstPath,true);
 		d.writeInput(s);
 		s.close();
 		d.close();

+ 4 - 4
std/cs/_std/sys/FileSystem.hx

@@ -33,9 +33,9 @@ class FileSystem {
 		return (File.Exists(path) || Directory.Exists(path));
 	}
 
-	public static function rename( path : String, newpath : String ) : Void
+	public static function rename( path : String, newPath : String ) : Void
 	{
-		Directory.Move(path, newpath);
+		Directory.Move(path, newPath);
 	}
 
 	public static function stat( path : String ) : FileStat
@@ -77,9 +77,9 @@ class FileSystem {
 
 	}
 
-	public static function fullPath( relpath : String ) : String
+	public static function fullPath( relPath : String ) : String
 	{
-		return new FileInfo(relpath).FullName;
+		return new FileInfo(relPath).FullName;
 	}
 
 	public static function isDirectory( path : String ) : Bool

+ 2 - 2
std/cs/_std/sys/io/File.hx

@@ -84,8 +84,8 @@ class File {
 		return new FileOutput(stream);
 	}
 
-	public static function copy( src : String, dst : String ) : Void
+	public static function copy( srcPath : String, dstPath : String ) : Void
 	{
-		cs.system.io.File.Copy(src, dst);
+		cs.system.io.File.Copy(srcPath, dstPath);
 	}
 }

+ 5 - 5
std/java/_std/sys/FileSystem.hx

@@ -31,11 +31,11 @@ class FileSystem {
 		return new File(path).exists();
 	}
 
-	public static function rename( path : String, newpath : String ) : Void
+	public static function rename( path : String, newPath : String ) : Void
 	{
-		if (!new File(path).renameTo(new File(newpath)))
+		if (!new File(path).renameTo(new File(newPath)))
 		{
-			throw "Cannot rename " + path + " to " + newpath;
+			throw "Cannot rename " + path + " to " + newPath;
 		}
 	}
 
@@ -59,9 +59,9 @@ class FileSystem {
 		};
 	}
 
-	public static function fullPath( relpath : String ) : String
+	public static function fullPath( relPath : String ) : String
 	{
-		return new File(relpath).getAbsolutePath();
+		return new File(relPath).getAbsolutePath();
 	}
 
 	public static function isDirectory( path : String ) : Bool

+ 3 - 3
std/java/_std/sys/io/File.hx

@@ -103,14 +103,14 @@ class File {
 		}
 	}
 
-	public static function copy( src : String, dst : String ) : Void
+	public static function copy( srcPath : String, dstPath : String ) : Void
 	{
 		var r:FileInput = null;
 		var w:FileOutput = null;
 		try
 		{
-			r = read(src);
-			w = write(dst);
+			r = read(srcPath);
+			w = write(dstPath);
 			w.writeInput(r);
 		}
 

+ 4 - 4
std/neko/_std/sys/FileSystem.hx

@@ -34,8 +34,8 @@ class FileSystem {
 		return sys_exists(untyped path.__s);
 	}
 
-	public static function rename( path : String, newpath : String ) : Void {
-		untyped sys_rename(path.__s,newpath.__s);
+	public static function rename( path : String, newPath : String ) : Void {
+		untyped sys_rename(path.__s,newPath.__s);
 	}
 
 	public static function stat( path : String ) : FileStat {
@@ -46,8 +46,8 @@ class FileSystem {
 		return s;
 	}
 
-	public static function fullPath( relpath : String ) : String {
-		return new String(file_full_path(untyped relpath.__s));
+	public static function fullPath( relPath : String ) : String {
+		return new String(file_full_path(untyped relPath.__s));
 	}
 
 	static function kind( path : String ) : FileKind {

+ 3 - 3
std/neko/_std/sys/io/File.hx

@@ -58,9 +58,9 @@ enum FileHandle {
 		return untyped new FileOutput(file_open(path.__s,(if( binary ) "ab" else "a").__s));
 	}
 
-	public static function copy( src : String, dst : String ) : Void {
-		var s = read(src,true);
-		var d = write(dst,true);
+	public static function copy( srcPath : String, dstPath : String ) : Void {
+		var s = read(srcPath,true);
+		var d = write(dstPath,true);
 		d.writeInput(s);
 		s.close();
 		d.close();

+ 4 - 4
std/php/_std/sys/FileSystem.hx

@@ -34,8 +34,8 @@ class FileSystem {
 		return untyped __call__("file_exists", path);
 	}
 
-	public static inline function rename( path : String, newpath : String ) : Void {
-		untyped __call__("rename", path, newpath);
+	public static inline function rename( path : String, newPath : String ) : Void {
+		untyped __call__("rename", path, newPath);
 	}
 
 	public static function stat( path : String ) : FileStat {
@@ -55,8 +55,8 @@ class FileSystem {
 		};
 	}
 
-	public static inline function fullPath( relpath : String ) : String {
-		var p = untyped __call__("realpath", relpath);
+	public static inline function fullPath( relPath : String ) : String {
+		var p = untyped __call__("realpath", relPath);
 		if (untyped __physeq__(p, false))
 			return null;
 		else

+ 2 - 2
std/php/_std/sys/io/File.hx

@@ -56,8 +56,8 @@ enum FileHandle {
 		return untyped new FileOutput(untyped __call__('fopen', path, binary ? "ab" : "a"));
 	}
 
-	public static function copy( src : String, dst : String ) : Void {
-		untyped __call__("copy", src, dst);
+	public static function copy( srcPath : String, dstPath : String ) : Void {
+		untyped __call__("copy", srcPath, dstPath);
 	}
 
 }