/simpletypesystem/trunk

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/simpletypesystem/trunk

« back to all changes in this revision

Viewing changes to tests/main.c

  • Committer: Gustav Hartvigsson
  • Date: 2016-02-01 14:11:35 UTC
  • mto: This revision was merged to the branch mainline in revision 122.
  • Revision ID: gustav.hartvigsson@gmail.com-20160201141135-pcl4m4gcf8r7t11e
* Made the GC switchable at rutime (once) when compiled with S_USE_GC set.
* replaced:
  * malloc ->   s_malloc
  * free ->     s_free
  * realloc ->  s_realloc
  * calloc ->   s_calloc

* Made s_[malloc, calloc, free, realloc] functions and moved them to their own file.
  This can be used os basis for other memory stuffs in the future, if we want to use
  a Slab allocator or something else.

Show diffs side-by-side

added added

removed removed

Lines of Context:
4
4
#include <string.h>
5
5
#include <stdint.h>
6
6
 
 
7
#include <SimpleTypeSystem.h>
 
8
 
7
9
#include "test_macros.h"
8
10
#include "refcount.h"
9
11
#include "to_string.h"
18
20
int main  (int argc, char ** argv, char ** argp) {
19
21
  setup_suite ("SSTS");
20
22
 
 
23
  s_mm_init (S_MM_TYPE_GC);
 
24
 
21
25
  test_unit (test_refcount, "Refcount");
22
26
  test_unit (test_to_string, "To String");
23
27
  test_unit (test_error, "Error");
28
32
  test_unit (test_main_loop, "Main Loop");
29
33
  //test_unit (test_thread, "Threading");
30
34
 
 
35
  s_mm_cleanup ();
 
36
 
31
37
  end_suite ();
32
38
}