data_structures
stack_new.c
Go to the documentation of this file.
1 /* ************************************************************************** */
3 /* */
4 /* ::: :::::::: */
5 /* stack_new.c :+: :+: :+: */
6 /* +:+ +:+ +:+ */
7 /* By: unite <marvin@42.fr> +#+ +:+ +#+ */
8 /* +#+#+#+#+#+ +#+ */
9 /* Created: 2020/07/17 00:48:57 by unite #+# #+# */
10 /* Updated: 2020/07/17 00:49:46 by unite ### ########.fr */
11 /* */
12 /* ************************************************************************** */
13 
14 #include "stack.h"
15 
16 t_stack *stack_new(const t_type *type)
17 {
18  return (array_new(type));
19 }
s_type
A full representation of a data type, used to achieve polymorphism in the implementation of data stru...
Definition: types.h:47
s_array
A resizable array.
Definition: array.h:47
array_new
t_array * array_new(const t_type *type)
Initializes a new empty array.
Definition: array_new.c:16
stack_new
t_stack * stack_new(const t_type *type)
Initializes an empty stack.
Definition: stack_new.c:16
stack.h