diff options
Diffstat (limited to 'examples')
| -rw-r--r-- | examples/demos.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/demos.c b/examples/demos.c index ac7cd810..1304cf85 100644 --- a/examples/demos.c +++ b/examples/demos.c @@ -13,7 +13,7 @@ void stringdemo1() cstr_erase_n(&cs, 7, 5); // -nine
printf("%s.\n", cstr_str(&cs));
- cstr_replace(&cs, cstr_find(cs, "seven"), 5, "four");
+ cstr_replace_first(&cs, "seven", "four");
printf("%s.\n", cstr_str(&cs));
cstr_take(&cs, cstr_from_fmt("%s *** %s", cstr_str(&cs), cstr_str(&cs)));
|
