Ignore:
Timestamp:
Nov 10, 2005, 5:28:36 PM (17 years ago)
Author:
Sam Hocevar
Message:
  • fixed 64 bit issues here and there.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • abuse/trunk/src/include/lisp.hpp

    r2 r11  
    11#ifndef __LISP_HPP_
    22#define __LISP_HPP_
     3
     4#include <stdint.h>
    35
    46#include "lisp_opt.hpp"
     
    3537       L_FIXED_POINT, L_COLLECTED_OBJECT };
    3638
    37 typedef long ltype;    // make sure structures aren't packed differently on various compiler
     39typedef uint64_t ltype;    // make sure structures aren't packed differently on various compiler
    3840                       // and sure that word, etc are word alligned
    3941
     
    8385  ltype type;
    8486#ifndef NO_LIBS
    85   long alist,blist;      // id for cached blocks
     87  intptr_t alist,blist;      // id for cached blocks
    8688#else
    8789  void *arg_list,*block_list;
     
    104106{
    105107  ltype type;
    106   short pad;
    107   unsigned short ch;
     108  int16_t pad;
     109  uint16_t ch;
    108110} ;
    109111
     
    118120{
    119121  ltype type;
    120   long x;
     122  int32_t x;
    121123} ;
    122124
     
    156158
    157159void push_onto_list(void *object, void *&list);
    158 lisp_symbol *add_c_object(void *symbol, short number);
     160lisp_symbol *add_c_object(void *symbol, int16_t number);
    159161lisp_symbol *add_c_function(char *name, short min_args, short max_args, short number);
    160162lisp_symbol *add_c_bool_fun(char *name, short min_args, short max_args, short number);
     
    167169lisp_number *new_lisp_number(long num);
    168170lisp_pointer *new_lisp_pointer(void *addr);
    169 lisp_character *new_lisp_character(unsigned short ch);
     171lisp_character *new_lisp_character(uint16_t ch);
    170172lisp_string *new_lisp_string(char *string);
    171173lisp_string *new_lisp_string(char *string, int length);
    172 lisp_string *new_lisp_string(long length);
    173 lisp_fixed_point *new_lisp_fixed_point(long x);
    174 lisp_object_var *new_lisp_object_var(short number);
    175 lisp_1d_array   *new_lisp_1d_array(unsigned short size, void *rest);
     174lisp_string *new_lisp_string(int length);
     175lisp_fixed_point *new_lisp_fixed_point(int32_t x);
     176lisp_object_var *new_lisp_object_var(int16_t number);
     177lisp_1d_array   *new_lisp_1d_array(int size, void *rest);
    176178lisp_sys_function *new_lisp_sys_function(int min_args, int max_args, int fun_number);
    177179lisp_sys_function *new_lisp_c_function(int min_args, int max_args, int fun_number);
     
    181183lisp_user_function *new_lisp_user_function(void *arg_list, void *block_list);
    182184#else
    183 lisp_user_function *new_lisp_user_function(long arg_list, long block_list);
     185lisp_user_function *new_lisp_user_function(intptr_t arg_list, intptr_t block_list);
    184186#endif
    185187
Note: See TracChangeset for help on using the changeset viewer.