소스 검색

improve fastCodeAt for python

frabbit 11 년 전
부모
커밋
176ee6045e
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      std/StringTools.hx

+ 1 - 1
std/StringTools.hx

@@ -377,7 +377,7 @@ class StringTools {
 		return (untyped s).charCodeAt(index);
 			#end
 		#elseif python
-		return if (index >= s.length) -1 else untyped(ord(untyped s[index]));
+		return if (index >= s.length) -1 else python.lib.Builtin.ord(python.Syntax.arrayAccess(s, index));
 		#else
 		return s.cca(index);
 		#end