Ignore:
Timestamp:
Jul 15, 2008, 1:25:26 PM (11 years ago)
Author:
gb
Message:

Kinder, gentler macros; may confuse C compiler less.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/win64/lisp-kernel/macros.h

    r8547 r10038  
    2222#define __macros__
    2323
    24 #define ptr_to_lispobj(p) ((LispObj)((unsigned_of_pointer_size)(p)))
    25 #define ptr_from_lispobj(o) ((LispObj*)((unsigned_of_pointer_size)(o)))
     24#define ptr_to_lispobj(p) ((LispObj)(p))
     25#define ptr_from_lispobj(o) ((LispObj*)(o))
    2626#define lisp_reg_p(reg)  ((reg) >= fn)
    2727
     
    3232#define indirect_node(o) (*(LispObj *)(node_aligned(o)))
    3333
    34 #define deref(o,n) (*((LispObj*) (ptr_from_lispobj(untag((LispObj)o)))+(n)))
     34#define deref(o,n) ((((LispObj*) (untag((LispObj)o))))[(n)])
    3535#define header_of(o) deref(o,0)
    3636
Note: See TracChangeset for help on using the changeset viewer.