summaryrefslogtreecommitdiff
path: root/rushs/evalexpr/stack
diff options
context:
space:
mode:
authorMartial Simon <msimon_fr@hotmail.com>2025-10-11 22:19:00 +0200
committerMartial Simon <msimon_fr@hotmail.com>2025-10-11 22:19:00 +0200
commit73c2b00a10c5786ddeeacc915e233fd4df1c9321 (patch)
treee299ea4e8ac161b2b21170172ff8f182c1c3fe1a /rushs/evalexpr/stack
parentc9b6b9a5ca082fe7c1b6f58d7713f785a9eb6a5c (diff)
fix: evalexpr & tinyprintf contenaient toute la piscine
Diffstat (limited to 'rushs/evalexpr/stack')
-rw-r--r--rushs/evalexpr/stack/stack.c30
-rw-r--r--rushs/evalexpr/stack/stack.h14
2 files changed, 0 insertions, 44 deletions
diff --git a/rushs/evalexpr/stack/stack.c b/rushs/evalexpr/stack/stack.c
deleted file mode 100644
index 0498abc..0000000
--- a/rushs/evalexpr/stack/stack.c
+++ /dev/null
@@ -1,30 +0,0 @@
-#include "stack.h"
-
-#include <stdlib.h>
-
-struct stack *stack_push(struct stack *s, int e)
-{
- struct stack *new = malloc(sizeof(struct stack));
- new->data = e;
- new->next = NULL;
-
- new->next = s;
- return new;
-}
-
-struct stack *stack_pop(struct stack *s)
-{
- if (s == NULL)
- {
- return NULL;
- }
-
- struct stack *res = s->next;
- free(s);
- return res;
-}
-
-int stack_peek(struct stack *s)
-{
- return s->data;
-}
diff --git a/rushs/evalexpr/stack/stack.h b/rushs/evalexpr/stack/stack.h
deleted file mode 100644
index bd5dd24..0000000
--- a/rushs/evalexpr/stack/stack.h
+++ /dev/null
@@ -1,14 +0,0 @@
-#ifndef STACK_H
-#define STACK_H
-
-struct stack
-{
- int data;
- struct stack *next;
-};
-
-struct stack *stack_push(struct stack *s, int e);
-struct stack *stack_pop(struct stack *s);
-int stack_peek(struct stack *s);
-
-#endif /* !STACK_H */