ilnw.c 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. #include "f2c.h"
  2. #include "fio.h"
  3. #include "lio.h"
  4. #ifdef __cplusplus
  5. extern "C" {
  6. #endif
  7. extern char *f__icptr;
  8. extern char *f__icend;
  9. extern icilist *f__svic;
  10. extern int f__icnum;
  11. #ifdef KR_headers
  12. extern void z_putc();
  13. #else
  14. extern void z_putc(int);
  15. #endif
  16. static int
  17. z_wSL(Void)
  18. {
  19. while(f__recpos < f__svic->icirlen)
  20. z_putc(' ');
  21. return z_rnew();
  22. }
  23. static void
  24. #ifdef KR_headers
  25. c_liw(a) icilist *a;
  26. #else
  27. c_liw(icilist *a)
  28. #endif
  29. {
  30. f__reading = 0;
  31. f__external = 0;
  32. f__formatted = 1;
  33. f__putn = z_putc;
  34. L_len = a->icirlen;
  35. f__donewrec = z_wSL;
  36. f__svic = a;
  37. f__icnum = f__recpos = 0;
  38. f__cursor = 0;
  39. f__cf = 0;
  40. f__curunit = 0;
  41. f__icptr = a->iciunit;
  42. f__icend = f__icptr + a->icirlen*a->icirnum;
  43. f__elist = (cilist *)a;
  44. }
  45. integer
  46. #ifdef KR_headers
  47. s_wsni(a) icilist *a;
  48. #else
  49. s_wsni(icilist *a)
  50. #endif
  51. {
  52. cilist ca;
  53. c_liw(a);
  54. ca.cifmt = a->icifmt;
  55. x_wsne(&ca);
  56. z_wSL();
  57. return 0;
  58. }
  59. integer
  60. #ifdef KR_headers
  61. s_wsli(a) icilist *a;
  62. #else
  63. s_wsli(icilist *a)
  64. #endif
  65. {
  66. f__lioproc = l_write;
  67. c_liw(a);
  68. return(0);
  69. }
  70. integer e_wsli(Void)
  71. {
  72. z_wSL();
  73. return(0);
  74. }
  75. #ifdef __cplusplus
  76. }
  77. #endif