Status: New
Owner: ----
New issue 292 by tanyingyu2008: How to use other character sets (GB or BIG5
or UTF-8 or unicode... )?
http://code.google.com/p/v8/issues/detail?id=292
in my JS (print chinese language):
print ("现在时间是");
shell.cc
v8::Handle<v8::Value> Print(const v8::Arguments& args) {
bool first = true;
for (int i = 0; i < args.Length(); i++) {
v8::HandleScope handle_scope;
if (first) {
first = false;
} else {
printf("");
}
v8::String::Utf8Value str(args[i]);
const char* cstr = ToCString(str);
printf("%s",str);
}
printf("\n");
return v8::Undefined();
}
I got the result is "鐜板湪鏃堕棿鏄"
--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings
--~--~---------~--~----~------------~-------~--~----~
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
-~----------~----~----~----~------~----~------~--~---