浏览代码

test String.fromCharCode() outside of BMP (#8673)

Aleksandr Kuzmenko 6 年之前
父节点
当前提交
e0c1286ce2
共有 1 个文件被更改,包括 4 次插入0 次删除
  1. 4 0
      tests/unit/src/unitstd/Unicode.unit.hx

+ 4 - 0
tests/unit/src/unitstd/Unicode.unit.hx

@@ -11,6 +11,10 @@ s == "あ";
 s.length == 1;
 s.charCodeAt(0) == "あ".code;
 
+//outside of BMP
+var s = String.fromCharCode("𠜎".code);
+s == "𠜎";
+
 var s = "aa😂éé";
 s.indexOf(String.fromCharCode(0x80))<0;
 s.indexOf("é")==s.length-2;