summaryrefslogtreecommitdiffhomepage
path: root/examples/csmap_erase.c
diff options
context:
space:
mode:
authorTyge Løvset <[email protected]>2022-09-23 07:15:41 +0200
committerTyge Løvset <[email protected]>2022-09-23 07:15:41 +0200
commit34bec4fdf406caff8492d53f0afc80df5d75bba4 (patch)
tree94252139eb34cb37f561ec5a6b9513629b2a81a5 /examples/csmap_erase.c
parentd70bcf4d875c14da30a39acfc37d00391cc1e7a9 (diff)
downloadSTC-modified-34bec4fdf406caff8492d53f0afc80df5d75bba4.tar.gz
STC-modified-34bec4fdf406caff8492d53f0afc80df5d75bba4.zip
Deprecated c_forarray, c_forarray_p macros - both replaced by c_forlist, and is consistent with other c_for* macros.
Diffstat (limited to 'examples/csmap_erase.c')
-rw-r--r--examples/csmap_erase.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/csmap_erase.c b/examples/csmap_erase.c
index cbcc2607..e99a4d7a 100644
--- a/examples/csmap_erase.c
+++ b/examples/csmap_erase.c
@@ -37,13 +37,13 @@ int main()
c_auto (mymap, m2)
{
// Fill in some data to test with, one at a time
- c_forarray (mymap_raw, v, {
+ c_forlist (i, mymap_raw, {
{10, "Bob"},
{11, "Rob"},
{12, "Robert"},
{13, "Bert"},
{14, "Bobby"},
- }) mymap_emplace(&m2, v->first, v->second);
+ }) mymap_emplace(&m2, c_pair(i.ref));
puts("Starting data of map m2 is:");
printmap(m2);