pike.git/
src/
builtin_functions.c
Branch:
Tag:
Non-build tags
All tags
No tags
2018-04-22
2018-04-22 20:50:43 by Henrik Grubbström (Grubba) <grubba@grubba.org>
81ac8ed3d4d3bd2a48c0d1bc4353c2be8f356192 (
17
lines) (+
9
/-
8
)
[
Show
|
Annotate
]
Branch:
master
Efuns: Use utf8_string in string_to_utf8() and utf8_to_string().
2144:
} }
-
/*! @decl string
(0..255)
string_to_utf8(string s)
-
*! @decl string
(0..255)
string_to_utf8(string s, int extended)
+
/*! @decl
utf8_
string string_to_utf8(string s)
+
*! @decl
utf8_
string string_to_utf8(string s, int extended)
*! *! Converts a string into an UTF-8 compliant byte-stream. *!
2290:
push_string(out); }
-
/*! @decl string utf8_to_string(string
(0..255)
s)
-
*! @decl string utf8_to_string(string
(0..255)
s, int extended)
+
/*! @decl string utf8_to_string(
utf8_
string s)
+
*! @decl string utf8_to_string(
utf8_
string s, int extended)
*! *! Converts an UTF-8 byte-stream into a string. *!
9842:
ADD_EFUN("unicode_to_string", f_unicode_to_string, tFunc(tStr8 tOr(tInt02,tVoid),tStr), OPT_TRY_OPTIMIZE);
-
/* function(string,int|void:string
(0..255
)
)
*/
+
/* function(string,int|void:
utf8_
string) */
ADD_EFUN("string_to_utf8", f_string_to_utf8,
-
tFunc(tStr tOr(tInt,tVoid),
tStr8
), OPT_TRY_OPTIMIZE);
+
tFunc(tStr tOr(tInt,tVoid),
tUtf8Str
), OPT_TRY_OPTIMIZE);
ADD_EFUN("string_filter_non_unicode", f_string_filter_non_unicode, tFunc(tStr tOr(tInt,tVoid),tStr8), OPT_TRY_OPTIMIZE);
-
/* function(string
(0..255)
,int|void:string) */
+
/* function(
utf8_
string,int|void:string) */
ADD_EFUN("utf8_to_string", f_utf8_to_string,
-
tFunc(
tStr8
tOr(tInt,tVoid),tStr), OPT_TRY_OPTIMIZE);
+
tFunc(
tUtf8Str
tOr(tInt,tVoid),tStr), OPT_TRY_OPTIMIZE);
ADD_EFUN("__parse_pike_type", f_parse_pike_type,