Changeset 490 for abuse/trunk/src/lisp/lisp.h
- Timestamp:
- Apr 17, 2011, 10:28:44 AM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
abuse/trunk/src/lisp/lisp.h
r489 r490 11 11 #define __LISP_HPP_ 12 12 13 #include <cstdlib> 13 14 #include <stdint.h> 14 15 … … 56 57 struct LispList : LispObject 57 58 { 58 void *cdr, *car; 59 size_t GetLength(); 60 61 LispObject *cdr, *car; 59 62 }; 60 63 … … 150 153 }; 151 154 152 static inline void*&CAR(void *x) { return ((LispList *)x)->car; }153 static inline void*&CDR(void *x) { return ((LispList *)x)->cdr; }155 static inline LispObject *&CAR(void *x) { return ((LispList *)x)->car; } 156 static inline LispObject *&CDR(void *x) { return ((LispList *)x)->cdr; } 154 157 static inline ltype item_type(void *x) { if (x) return *(ltype *)x; return L_CONS_CELL; } 155 158 … … 166 169 void *lisp_eq(void *n1, void *n2); 167 170 void *lisp_equal(void *n1, void *n2); 168 long list_length(void *i);169 171 void lprint(void *i); 170 172 void *eval(void *prog);
Note: See TracChangeset
for help on using the changeset viewer.