Commit 26d10f52 authored by Mehdy Leroux's avatar Mehdy Leroux
Browse files

fin Tp2

parent 5464b3eb
Loading
Loading
Loading
Loading
+4.11 KiB (13.8 KiB)

File changed.

No diff preview for this file type.

+0 −1
Changes for src/hash_tbl.c: 0 added lines, 1 removed line.
Original line number Diff line number Diff line
@@ -8,7 +8,6 @@ struct hash_tbl {
  int (*eq)(void*, void*);
  void (*free)(void*);
  unsigned long int size;
  unsigned long int capacity;
  size_t capacity; // array length
  list_t* array;
};
+48 B (4.59 KiB)

File changed.

No diff preview for this file type.

+48 B (6.28 KiB)

File changed.

No diff preview for this file type.

+5 −4
Changes for tests/htbl_tests.c: 5 added lines, 4 removed lines.
Original line number Diff line number Diff line
@@ -23,6 +23,7 @@ void test_empty() {
  printf("test_empty OK\n");
}


void test_add() {
  char a[] = "Coucou 1";
  char b[] = "Coucou 2";
@@ -63,13 +64,13 @@ void test_destroy() {
  printf("test_destroy OK\n");
}


int main() {
  printf("=== HTBL tests ===\n");
  test_empty();
  test_add();
  test_in();
  test_destroy();
  //test_add();
  //test_in();
  //test_destroy();

  return 0;
}
  
Loading