this still does not work though
This commit is contained in:
@@ -1,14 +1,20 @@
|
|||||||
#include <odweta/vector.h>
|
#include <odweta/vector.h>
|
||||||
|
#include <odweta/string.h>
|
||||||
|
|
||||||
int main() {
|
int main() {
|
||||||
vector_t *v = vector_new(INT);
|
string_t *s = string_from("test string");
|
||||||
|
string_t *s2 = string_from("another test");
|
||||||
|
|
||||||
vector_push(v, &(int){1});
|
vector_t *v = vector_new(STRING);
|
||||||
vector_push(v, &(int){2});
|
|
||||||
vector_push(v, &(int){3});
|
vector_push(v, s);
|
||||||
|
vector_push(v, s2);
|
||||||
|
|
||||||
vector_print(v);
|
vector_print(v);
|
||||||
|
|
||||||
|
string_cleanup(s);
|
||||||
|
string_cleanup(s2);
|
||||||
|
|
||||||
vector_cleanup(v);
|
vector_cleanup(v);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|||||||
Reference in New Issue
Block a user