summaryrefslogtreecommitdiffhomepage
path: root/misc/examples/utf8replace_c.c
diff options
context:
space:
mode:
authorTyge Løvset <[email protected]>2022-12-29 00:28:50 +0100
committerTyge Løvset <[email protected]>2022-12-29 00:28:50 +0100
commit0761c13f316cc98ae7756f3527931aa86bed5016 (patch)
treee90777558956fcf91d6b1c958e0c3a6fb0ab007f /misc/examples/utf8replace_c.c
parentd623c6c85071b9af5d607bb5d9aceceaea05220a (diff)
downloadSTC-modified-0761c13f316cc98ae7756f3527931aa86bed5016.tar.gz
STC-modified-0761c13f316cc98ae7756f3527931aa86bed5016.zip
Restructuring of some headers into include/algo folder. Some API changes *_replace*() functions have been renamed, and a few minor API changes.
Diffstat (limited to 'misc/examples/utf8replace_c.c')
-rw-r--r--misc/examples/utf8replace_c.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/misc/examples/utf8replace_c.c b/misc/examples/utf8replace_c.c
index 74b765dc..3645bd0a 100644
--- a/misc/examples/utf8replace_c.c
+++ b/misc/examples/utf8replace_c.c
@@ -8,10 +8,10 @@ int main() {
printf("%s\n", cstr_str(&hello));
/* replace second smiley at utf8 codepoint pos 7 */
- cstr_u8_replace(&hello, cstr_u8_to_pos(&hello, 7), 1, c_SV("🐨"));
+ cstr_u8_replace_at(&hello, cstr_u8_to_pos(&hello, 7), 1, c_SV("🐨"));
printf("%s\n", cstr_str(&hello));
- cstr_replace(&hello, "🐨", "ø", 1);
+ cstr_replace_ex(&hello, "🐨", "ø", 1);
printf("%s\n", cstr_str(&hello));
upper = cstr_toupper_sv(cstr_sv(&hello));