4 * Copyright 2004-2009 by Marc Feeley and Vincent St-Amour, All Rights Reserved.
9 #include "picobit-vm.h"
10 // needs some memory access functions defined above
14 void show_type (obj o
) // for debugging purposes
17 if (o
== OBJ_FALSE
) printf("#f");
18 else if (o
== OBJ_TRUE
) printf("#t");
19 else if (o
== OBJ_NULL
) printf("()");
20 else if (o
< MIN_ROM_ENCODING
) printf("fixnum");
23 if (RAM_BIGNUM(o
)) printf("ram bignum");
24 else if (RAM_PAIR(o
)) printf("ram pair");
25 else if (RAM_SYMBOL(o
)) printf("ram symbol");
26 else if (RAM_STRING(o
)) printf("ram string");
27 else if (RAM_VECTOR(o
)) printf("ram vector");
28 else if (RAM_CONTINUATION(o
)) printf("ram continuation");
29 else if (RAM_CLOSURE(o
)) printf("ram closure");
33 if (ROM_BIGNUM(o
)) printf("rom bignum");
34 else if (ROM_PAIR(o
)) printf("rom pair");
35 else if (ROM_SYMBOL(o
)) printf("rom symbol");
36 else if (ROM_STRING(o
)) printf("rom string");
37 else if (ROM_VECTOR(o
)) printf("rom vector");
38 else if (ROM_CONTINUATION(o
)) printf("rom continuation");
39 else if (RAM_CLOSURE(o
)) printf("rom closure");