home *** CD-ROM | disk | FTP | other *** search
/ Oakland CPM Archive / oakcpm.iso / sigm / vol167 / update.cnv < prev    next >
Encoding:
Text File  |  1984-04-29  |  880 b   |  62 lines

  1.  
  2. [UPDATE.CNV]
  3. [Harold V. McIntosh, 28 January 1984]
  4.  
  5. []
  6.  
  7. [[Generate FILE.ONE using FILE.TWO and FILE.DIF]]
  8.  
  9.  
  10.  
  11. [record difference line]
  12. (()()(3 4)(
  13.     ((PWS,a: )(or),);
  14.     (<-->(^Z),(b,(T)));
  15.     (File 1<,> Line <3>: <4>,(c,(A))(D)):
  16.     (File 2<,> Line <3>: <4>,(d,(B))(D)):
  17.     (,(D)):
  18.   )) a
  19.  
  20. [copy remainder of file]
  21. (()()(2)(
  22.     (<-->(^Z),);
  23.     (<2>,(%W,<9>.ONE,<2>(%|))(T)):
  24.   )) b
  25.  
  26. [insert at given line]
  27. (()()()(
  28.     (<3>,(4));
  29.     (,(2)(A)(,(B))):
  30.   )) c
  31.  
  32. [delete a given line]
  33. (()()()(
  34.     (<3>,(,(T)));
  35.     (,(2)(,(A))(B)):
  36.   )) d
  37.  
  38. [main program]
  39. ((
  40.   )(
  41.     ((%R,CTR:F1)) A
  42.     ((%R,CTR:F2)) B
  43.     ((%R,<9>.TWO)) T
  44.     ((%R,<9>.DIF)) D
  45.     ((%W,<9>.ONE,(T)(%|))) 2
  46.     ((%W,<9>.ONE,<4>(%|))) 4
  47.   )(9)(
  48.     ((PWS)(or),);
  49.     (<9>(or, ,.,<>),<<
  50.         >>(%Or,<9>.TWO)<<
  51.         >>(%Or,<9>.DIF)<<
  52.         >>(%Ow,<9>.ONE)<<
  53.         >>(%Or,CTR:F1)<<
  54.         >>(%Or,CTR:F2)<<
  55.         >>(%W,CTR:F1,0,1)<<
  56.         >>(%W,CTR:F2,0,1)<<
  57.         >>(a,(D))<<
  58.         >>(%E));
  59.   ))
  60.  
  61. [end]
  62.