home *** CD-ROM | disk | FTP | other *** search
/ Stars of Shareware: Programmierung / SOURCE.mdf / programm / windows / c / xlisp21w / sources / xlglob.c < prev    next >
Encoding:
C/C++ Source or Header  |  1993-02-26  |  4.4 KB  |  143 lines

  1. /* xlglobals - xlisp global variables */
  2. /*  Copyright (c) 1985, by David Michael Betz
  3.         All Rights Reserved
  4.         Permission is granted for unrestricted non-commercial use   */
  5.  
  6. #include "xlisp.h"
  7.  
  8. /* symbols */
  9. struct node isnil;
  10.  
  11. LVAL true=NULL,obarray=NULL;
  12. LVAL s_unbound=NIL,s_dot=NULL;
  13. LVAL s_quote=NULL,s_function=NULL;
  14. LVAL s_bquote=NULL,s_comma=NULL,s_comat=NULL;
  15. LVAL s_evalhook=NULL,s_applyhook=NULL,s_tracelist=NULL;
  16. LVAL s_lambda=NULL,s_macro=NULL;
  17. LVAL s_stdin=NULL,s_stdout=NULL,s_stderr=NULL,s_debugio=NULL,s_traceout=NULL;
  18. LVAL s_rtable=NULL;
  19. LVAL s_tracenable=NULL,s_tlimit=NULL,s_breakenable=NULL;
  20. LVAL s_setf=NULL,s_car=NULL,s_cdr=NULL,s_nth=NULL,s_aref=NULL,s_get=NULL;
  21. LVAL s_svalue=NULL,s_sfunction=NULL,s_splist=NULL;
  22. LVAL s_eql=NULL,s_gcflag=NULL,s_gchook=NULL;
  23. LVAL s_ifmt=NULL,s_ffmt=NULL;
  24. #ifdef RATIOS
  25. LVAL s_rfmt=NULL;
  26. #endif
  27. LVAL s_1plus=NULL,s_2plus=NULL,s_3plus=NULL;
  28. LVAL s_1star=NULL,s_2star=NULL,s_3star=NULL;
  29. LVAL s_minus=NULL,s_printcase=NULL;
  30. LVAL s_printlevel=NULL, s_printlength=NULL;
  31. LVAL s_dispmacros=NULL;
  32. LVAL s_strtypep=NULL, s_mkstruct=NULL, s_cpystruct=NULL;
  33. LVAL s_strref=NULL, s_strset=NULL;
  34. LVAL s_x=NULL, s_s=NULL, s_sslots=NULL;
  35. LVAL s_elt = NULL;
  36. LVAL a_list=NULL, a_number=NULL, a_null=NULL, a_atom=NULL, a_anystream=NULL;
  37. LVAL s_and=NULL, s_or=NULL, s_not=NULL, s_satisfies=NULL, s_member=NULL;
  38. LVAL a_struct = NULL;
  39. #ifdef DOSINPUT
  40. LVAL s_dosinput=NULL;
  41. #endif
  42. #ifdef HASHFCNS
  43. LVAL s_gethash = NULL, a_hashtable = NULL;
  44. #endif
  45. #ifdef COMPLX
  46. LVAL a_complex = NULL;
  47. #endif
  48. #ifdef RANDOM
  49. LVAL s_randomstate=NULL, a_randomstate=NULL;
  50. #endif
  51. #ifdef READTABLECASE
  52. LVAL s_rtcase=NULL;
  53. #endif
  54.  
  55.  
  56. /* keywords */
  57. LVAL k_test=NULL,k_tnot=NULL;
  58. LVAL k_wspace=NULL,k_const=NULL,k_nmacro=NULL,k_tmacro=NULL;
  59. LVAL k_sescape=NULL,k_mescape=NULL;
  60. LVAL k_direction=NULL,k_input=NULL,k_output=NULL;
  61. LVAL k_start=NULL,k_end=NULL,k_1start=NULL,k_1end=NULL;
  62. LVAL k_2start=NULL,k_2end=NULL,k_count=NULL;
  63. LVAL k_verbose=NULL,k_print=NULL;
  64. LVAL k_upcase=NULL,k_downcase=NULL;
  65. LVAL k_io=NULL, k_elementtype=NULL;
  66. LVAL s_termio=NULL, k_exist=NULL, k_nexist=NULL, k_error=NULL;
  67. LVAL k_rename=NULL, k_newversion=NULL, k_overwrite=NULL, k_append=NULL;
  68. LVAL k_supersede=NULL, k_rendel=NULL, k_probe=NULL, k_create=NULL;
  69. LVAL k_concname=NULL, k_include=NULL;
  70. #ifdef REDUCE
  71. LVAL k_ivalue=NULL;
  72. #endif
  73. #ifdef KEYARG
  74. LVAL k_key=NULL;
  75. #endif
  76. #ifdef HASHFCNS
  77. LVAL k_size = NULL;
  78. #endif
  79. #ifdef RANDOM
  80. LVAL k_data=NULL;
  81. #endif
  82. #ifdef READTABLECASE
  83. LVAL k_preserve=NULL,k_invert=NULL;
  84. #endif
  85.  
  86.  
  87. /* lambda list keywords */
  88. LVAL lk_optional=NULL,lk_rest=NULL,lk_key=NULL,lk_aux=NULL;
  89. LVAL lk_allow_other_keys=NULL;
  90.  
  91. /* type names */
  92. LVAL a_subr=NULL,a_fsubr=NULL;
  93. LVAL a_cons=NULL,a_symbol=NULL,a_fixnum=NULL,a_flonum=NULL;
  94. LVAL a_string=NULL,a_object=NULL,a_stream=NULL,a_vector=NULL;
  95. LVAL a_closure=NULL,a_char=NULL,a_ustream=NULL;
  96. #ifdef RATIOS
  97. LVAL a_ratio=NULL;
  98. LVAL a_rational=NULL;
  99. #endif
  100.  
  101. /* evaluation variables */
  102. LVAL * XNEAR xlstkbase[EDEPTH];
  103. LVAL * XNEAR *xlstack = NULL;
  104. LVAL xlenv=NULL,xlfenv=NULL,xldenv=NULL;
  105.  
  106. /* argument stack */
  107. LVAL XNEAR xlargstkbase[ADEPTH]; /* argument stack */
  108. LVAL XNEAR *xlfp = NULL;         /* argument frame pointer */
  109. LVAL XNEAR *xlsp = NULL;         /* argument stack pointer */
  110. LVAL XNEAR *xlargv = NULL;       /* current argument vector */
  111. int xlargc = 0;         /* current argument count */
  112.  
  113. /* exception handling variables */
  114. CONTEXT *xlcontext = NULL;  /* current exception handler */
  115. CONTEXT *xltarget = NULL;   /* target context (for xljump) */
  116. LVAL xlvalue=NULL;      /* exception value (for xljump) */
  117. int xlmask=0;           /* exception type (for xljump) */
  118.  
  119. /* debugging variables */
  120. int xldebug = 0;        /* debug level */
  121. int xlsample = 0;       /* control character sample rate */
  122. int xltrcindent = 0;        /* trace indent level */
  123.  
  124. /* gensym variables */
  125. char gsprefix[STRMAX+1] = { 'G',0 };    /* gensym prefix string */
  126. FIXTYPE gsnumber = 1;       /* gensym number */
  127.  
  128. /* i/o variables */
  129. int xlfsize = 0;        /* flat size of current print call */
  130. FILEP tfp = CLOSED;     /* transcript file pointer */
  131.  
  132. /* general purpose string buffer */
  133. char buf[STRMAX+1] = { 0 };
  134.  
  135. #ifdef FILETABLE
  136. FILETABLETYPE filetab[FTABSIZE] =
  137. {{stdin,"(stdin)"},
  138.  {stdout,"(stdout)"},
  139.  {stderr,"(console)"},
  140.  {0,""}};
  141. #endif
  142. /* $putpatch.c$: "MODULE_XLGLOB_C_GLOBALS" */
  143.