summaryrefslogtreecommitdiffhomepage
path: root/examples/stack.c
diff options
context:
space:
mode:
Diffstat (limited to 'examples/stack.c')
-rw-r--r--examples/stack.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/examples/stack.c b/examples/stack.c
index 54d5aeed..dac0112e 100644
--- a/examples/stack.c
+++ b/examples/stack.c
@@ -11,9 +11,8 @@
#include <stc/cstack.h>
int main() {
- cstack_i stack = cstack_i_init();
- cstack_c chars = cstack_c_init();
- c_autodefer (cstack_i_del(&stack), cstack_c_del(&chars))
+ c_auto (cstack_i, stack)
+ c_auto (cstack_c, chars)
{
c_forrange (i, int, 101)
cstack_i_push(&stack, i*i);