瀏覽代碼

minor haxe.io.Path optimization - use StringTools.fastCodeAt where index is guaranteed to be valid

Dan Korostelev 8 年之前
父節點
當前提交
490c0052ae
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      std/haxe/io/Path.hx

+ 1 - 1
std/haxe/io/Path.hx

@@ -229,7 +229,7 @@ class Path {
 		var colon = false;
 		var slashes = false;
 		for (i in 0...tmp.length) {
-			switch (tmp.charCodeAt(i)) {
+			switch (StringTools.fastCodeAt(tmp, i)) {
 				case ":".code:
 					acc.add(":");
 					colon = true;