forked from xxq250/Nasal-Interpreter
✨ add utf-8 identifier check in nasal_lexer & fix printf format at windows platform & add test file utf8chk.nas
This commit is contained in:
@@ -65,8 +65,9 @@ var testfile=[
|
||||
"test/tetris.nas ",
|
||||
"test/trait.nas ",
|
||||
"test/turingmachine.nas",
|
||||
"test/ycombinator.nas ",
|
||||
"test/wavecollapse.nas "
|
||||
"test/utf8chk.nas ",
|
||||
"test/wavecollapse.nas ",
|
||||
"test/ycombinator.nas "
|
||||
];
|
||||
|
||||
var module=[
|
||||
|
||||
11
test/utf8chk.nas
Normal file
11
test/utf8chk.nas
Normal file
@@ -0,0 +1,11 @@
|
||||
var 输出=print;
|
||||
var 这是unicode测试=func(){
|
||||
var 测试成功=[
|
||||
"unicode: utf-8支持测试成功",
|
||||
"目前仅支持utf-8以及ascii格式文件",
|
||||
"注意: windows系统请开启chcp 65001代码页"
|
||||
];
|
||||
foreach(var 内容;测试成功)
|
||||
输出(内容~"\n");
|
||||
}
|
||||
这是unicode测试();
|
||||
Reference in New Issue
Block a user