diff options
| author | Tyge Løvset <[email protected]> | 2022-12-23 23:55:10 +0100 |
|---|---|---|
| committer | Tyge Løvset <[email protected]> | 2022-12-23 23:55:10 +0100 |
| commit | d623c6c85071b9af5d607bb5d9aceceaea05220a (patch) | |
| tree | f20fc3714f86e1553d1103bed6dc8efefcbd9d6b /misc/examples/arcvec_erase.c | |
| parent | 5f57d597cd27aef55adbcb3b452973b0c6e33667 (diff) | |
| download | STC-modified-d623c6c85071b9af5d607bb5d9aceceaea05220a.tar.gz STC-modified-d623c6c85071b9af5d607bb5d9aceceaea05220a.zip | |
Experimental uppercase macros.
Diffstat (limited to 'misc/examples/arcvec_erase.c')
| -rw-r--r-- | misc/examples/arcvec_erase.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/misc/examples/arcvec_erase.c b/misc/examples/arcvec_erase.c index c70d59d9..eb54084a 100644 --- a/misc/examples/arcvec_erase.c +++ b/misc/examples/arcvec_erase.c @@ -15,9 +15,9 @@ void show_drop(int* x) { printf("drop: %d\n", *x); } int main() { - c_auto (Vec, vec) + c_AUTO (Vec, vec) { - c_forlist (i, int, {2012, 1990, 2012, 2019, 2015}) + c_FORLIST (i, int, {2012, 1990, 2012, 2019, 2015}) Vec_emplace(&vec, *i.ref); // clone the second 2012 and push it back. @@ -25,7 +25,7 @@ int main() Vec_push(&vec, Arc_clone(vec.data[2])); printf("vec before erase :"); - c_foreach (i, Vec, vec) + c_FOREACH (i, Vec, vec) printf(" %d", *i.ref->get); printf("\nerase vec.data[2]; or first matching value depending on compare.\n"); @@ -40,12 +40,12 @@ int main() Vec_erase_at(&vec, it); printf("vec after erase :"); - c_foreach (i, Vec, vec) + c_FOREACH (i, Vec, vec) printf(" %d", *i.ref->get); Vec_sort(&vec); printf("\nvec after sort :"); - c_foreach (i, Vec, vec) + c_FOREACH (i, Vec, vec) printf(" %d", *i.ref->get); puts("\nDone"); |
