home *** CD-ROM | disk | FTP | other *** search
/ The World of Computer Software / World_Of_Computer_Software-02-385-Vol-1of3.iso / t / tags18.zip / TEST.C < prev    next >
C/C++ Source or Header  |  1992-05-10  |  5KB  |  256 lines

  1. /*
  2.  EPSHeader
  3.  
  4.    File: test.c
  5.    Author: J. Kercheval
  6.    Created: Wed, 08/28/1991  20:53:31
  7. */
  8.  
  9. #ifndef BOOLEAN
  10. #define BOOLEAN int
  11. #define TRUE 1
  12. #define FALSE 0
  13. #endif
  14.  
  15. #include <stdio.h>
  16. #include "rwndwmd.h"
  17. #include "qmanager.h"
  18. #include "dbuggr.h"
  19. #include "dispat.h"
  20. #include "drivinit.h"
  21. #include "errors.h"
  22. #include "utils.h"
  23. #include "printer.h"
  24. #include "prstream.h"
  25. #include "resid.h"
  26. #include "wDialog.h"
  27. #include "werror.h"
  28. #include "wHelp.h"
  29. #ifdef HP
  30. #include "keymou.h"
  31. #include "reflect.h"
  32. #else /* HP */
  33. #include "prims.h"
  34. #include "zKeymou.h"
  35. #endif /* HP */
  36.  
  37. main2 ()
  38. {
  39.  
  40. enum
  41. {
  42.   FOO = 1,
  43.   BAR = 2,
  44. };
  45.  
  46. #ifdef HELLO
  47.     {
  48. #else
  49.     {
  50. #endif
  51.  
  52. #ifdef HELLO_AGAIN
  53. #elif
  54.     {
  55. #endif
  56.     }
  57. #define DEFINE_IN_MAIN2
  58. }
  59.  
  60. int hello2()
  61. {
  62.     hmmm;
  63. }
  64.  
  65. #define DEFPALETTE    /*0*/        RGB (0,        0,        0),        \
  66.                     /*1*/        RGB (128,    0,        0),        \
  67.                     /*2*/        RGB (0,        128,    0),        \
  68.                     /*3*/        RGB (0,        0,        128),    \
  69.                     /*4*/        RGB (128,    0,        128),    \
  70.                     /*5*/        RGB (0,        128,    128),    \
  71.                     /*6*/        RGB (128,    128,    0),        \
  72.                     /*7*/        RGB (192,    192,    192),    \
  73.                     /*8*/        RGB (128,    128,    128),    \
  74.                     /*9*/        RGB (255,    0,        0),        \
  75.                     /*10*/        RGB (0,        255,    0),        \
  76.                     /*11*/        RGB (255,    255,    0),        \
  77.                     /*12*/        RGB (0,        0,        255),    \
  78.                     /*13*/        RGB (255,    0,        255),    \
  79.                     /*14*/        RGB (0,        255,    255),    \
  80.                     /*15*/        RGB (255,    255,    255)
  81.  
  82. void (**curdt)(void) = dprimary; /* current dispatch table */
  83.  
  84. void *hello_again, (**curdt)(void) = dprimary, *goodbye_again;
  85.  
  86. /* This dispatch table corresponds to character table dfctab */
  87. static void (*dfdtab[7])() = {
  88.     /* first 5 entries correspond to IG, AK, D1, EE, D3 */
  89.     ignchar, ackit, havedc1, endesc, havedc3,
  90.  
  91.     dfchar
  92. };
  93.  
  94. char pRefPrinter[80];
  95.  
  96. #define CHART_DFLOAT                     make_index (0, DFloat)
  97.  
  98. #define Macro1(c) tolower(c)
  99.  
  100. typedef int (KEY_HANDLER) (SHORT id, int key);
  101.  
  102. #define define1 (bad)
  103.  
  104. typedef void (* INIT_DEINIT_FXN) (LSCREEN *scr);
  105.  
  106. typedef struct logical_screen
  107. {
  108. } LOGICAL_SCREEN, LSCREEN;
  109.  
  110. extern struct dirent * readdir (DIR *directory);
  111.  
  112. extern char * (*screen_item_name) (INDEX);
  113.  
  114. void (* dprimary[17])() =
  115. {
  116.     /* first 5 entries correspond to IG, AK, D1, EE, D3 */
  117.     ignchar, ackit, havedc1, endesc, havedc3,
  118.  
  119.     begstream, DoBell, backspace, dotab, linefeed,
  120. #ifdef _gr2393
  121.     carret, shiftout, shiftin, startesc, begtechgr,
  122. #else
  123.     carret, shiftout, shiftin, startesc, beggraph,
  124. #endif
  125.     blokterm, formfeed
  126. }, (* funcptr1[2])(), afterfuncptr;
  127.  
  128. // dde advise-link structure associating Refl variables with server app items
  129. typedef struct DDECLILINK {
  130.     ATOM      aItem;            // item name atom
  131.     short     nVar;            // number of reflection variable
  132. };
  133.  
  134. /* Possible KERMIT protocol states. */
  135. enum kermProtoStates {
  136.     _kmGetBytes = 2,
  137.     _kmNewRecvFile,
  138.     _kmNewSendFile = 4,
  139. };
  140.  
  141. enum silliness {
  142.     silly1,
  143.     silly2,
  144.     silly3
  145. };
  146.  
  147. static char *
  148. xmalloc(n)
  149.      int n;
  150. {
  151. }
  152.  
  153. struct DDECLILINK *proto3();
  154.  
  155. int proto1();
  156.  
  157. void (*proto2)();
  158.  
  159. typedef struct LL {
  160.     int c;
  161.     int d;
  162. } LL2;
  163.  
  164. LL2 t1;
  165. struct LL t2;
  166.  
  167. static struct __cside cModeCache[] = {    /* see cside[] in tabwrite.c */
  168.     {_cbaud,    0,    0},
  169.     {_cdatab,    0,    0},
  170.     {_chkpar,    0,    0},
  171.     {_xxonoff,    0,    0},
  172.     {_ctshnd,    0,    0},
  173.     {_rxonoff,    0,    0},
  174.     {_none8,    0,    0},
  175.     {_portsw,    0,    0},
  176.     {_Ihndshk,    0,    0},
  177.     {_Inhdc2,    0,    0},
  178.     {0}
  179. };
  180.  
  181. static void
  182. zaptemp(name)
  183.      char *name;
  184. {
  185.   struct tempnode *node, *temp;
  186.  
  187. }
  188.  
  189. // Borland C++ - (C) Copyright 1991 by Borland International
  190.  
  191. /*    HELLO.C -- Hello, world */
  192.  
  193. typedef char hello[20];
  194.  
  195. typedef struct {
  196.     char t;
  197.     int tt;
  198. } toodles[20];
  199.  
  200. typedef void (*typedef1)(char);
  201.  
  202. typedef BOOL (LINEFN) (int row, int col, struct scroll_box *sb);
  203.  
  204. #define ABORTXFER true+1 /* User hit abort key */
  205.  
  206. /*__________________________________________________________________________*/
  207. extern void fprompt(which)
  208. short which; /* 0 = send, 1 = receive */
  209. /*
  210.  * Do a prompted file transfer
  211.  */
  212. {
  213.     extern MODES curmodes;
  214.     extern char* nullstr;
  215.  
  216.     REGISTER Boolean oldqustat = curmodes.qustat;
  217.     REGISTER short oldrecsize = curmodes.recsize;
  218.  
  219.     setsmode(_locfile, nullstr);
  220.     setsmode(_hosfile, nullstr);
  221.     setfalse(_qustat);
  222.  
  223.     if (checkfiles(which, -1, true, true)) {
  224. #ifdef _Windows
  225.         rStatus |= rFTDialog | rFT;
  226.         initCWMenu();
  227. #endif
  228.         if (which == 0)
  229.               ftsend(-1, true);
  230.         else
  231.             ftrecv(-1, true);
  232. #ifdef _Windows
  233.         rStatus &= ~(rFTDialog | rFT);
  234.         initCWMenu();
  235. #endif
  236.     }
  237.     setmode(_qustat, (long)oldqustat);
  238.     setmode(_recsize, oldrecsize);
  239. }
  240.  
  241. int *(*hellotoyoutoo);
  242.  
  243. char c='l', h='t';
  244.  
  245. #define DEFINE_OUTSIDE_OF_MAIN()
  246.  
  247. int main()
  248. {
  249.     printf("Hello, world\n");
  250. #define DEFINE_IN_MAIN
  251.     return 0;
  252. }
  253. #define DEFINE_OUTSIDE_OF_MAIN()
  254.  
  255.  
  256.