summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex AUVOLAT <alex.auvolat@ens.fr>2013-11-18 16:02:59 +0100
committerAlex AUVOLAT <alex.auvolat@ens.fr>2013-11-18 16:02:59 +0100
commit9905bcc6c923ac896f6bddf80eaded250870b726 (patch)
treeb1d9967920b7299a3b30ef4b9d3e19d5c5428231
parentaba69b8e46b8b1f87bc667b62ae1f60ef42963ab (diff)
downloadAlgoProg-Projet-9905bcc6c923ac896f6bddf80eaded250870b726.tar.gz
AlgoProg-Projet-9905bcc6c923ac896f6bddf80eaded250870b726.zip
Changed a few files so that it will compile.
-rw-r--r--.gitignore2
-rw-r--r--Makefile8
-rw-r--r--main.c5
-rw-r--r--set_bitsets.c (renamed from set_bitset.c)0
-rw-r--r--set_linked_lists.c (renamed from set_linked_list.c)1
-rw-r--r--set_treaps.c3
-rw-r--r--sets.h6
7 files changed, 16 insertions, 9 deletions
diff --git a/.gitignore b/.gitignore
index b25c15b..dadcc46 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1,3 @@
*~
+*.swp
+exe_*
diff --git a/Makefile b/Makefile
index ce298f8..2714366 100644
--- a/Makefile
+++ b/Makefile
@@ -1,15 +1,15 @@
+all : exe_ll exe_bs exe_tr
-exe_ll : mainc.c sets.h set_linked_lists.c
+exe_ll : main.c sets.h set_linked_lists.c
gcc -o exe_ll main.c set_linked_lists.c -DLINKEDLISTS
-exe_bs : mainc.c sets.h set_bitsets.c
+exe_bs : main.c sets.h set_bitsets.c
gcc -o exe_bs main.c set_bitsets.c -DBITSETS
-exe_tr : mainc.c sets.h set_treaps.c
+exe_tr : main.c sets.h set_treaps.c
gcc -o exe_tr main.c set_treaps.c -DTREAPS
-all : exe_ll exe_bs exe_tr
clean :
rm exe_ll exe_tr exe_bs
diff --git a/main.c b/main.c
new file mode 100644
index 0000000..bfa27a1
--- /dev/null
+++ b/main.c
@@ -0,0 +1,5 @@
+#include "sets.h"
+
+int main() {
+ return 0;
+}
diff --git a/set_bitset.c b/set_bitsets.c
index 4be3b4b..4be3b4b 100644
--- a/set_bitset.c
+++ b/set_bitsets.c
diff --git a/set_linked_list.c b/set_linked_lists.c
index 0121589..f37773f 100644
--- a/set_linked_list.c
+++ b/set_linked_lists.c
@@ -1,4 +1,3 @@
#include "sets.h"
-struct _set {
diff --git a/set_treaps.c b/set_treaps.c
new file mode 100644
index 0000000..f37773f
--- /dev/null
+++ b/set_treaps.c
@@ -0,0 +1,3 @@
+#include "sets.h"
+
+
diff --git a/sets.h b/sets.h
index 937f867..59768f0 100644
--- a/sets.h
+++ b/sets.h
@@ -26,7 +26,7 @@ struct set_elt {
struct set_elt *next;
};
struct set {
- set_elt *first, *last;
+ struct set_elt *first, *last;
};
typedef struct set *set;
@@ -34,9 +34,7 @@ typedef struct set *set;
#ifdef TREAPS
// TODO
-#define main 0
-struct set;
-typedef struct set set;
+typedef void* set;
#endif