home *** CD-ROM | disk | FTP | other *** search
/ Acorn User 11 / AUCD11B.iso / LANGUAGES / WraithSet / AwkStuff / MawkSrc / Docs / README2 < prev    next >
Text File  |  1996-09-17  |  3KB  |  93 lines

  1. Mawk -- an implementation of new/posix awk
  2. version 1.3.2
  3.  
  4. Installation instructions in file INSTALL.
  5.  
  6. Bug reports, comments, questions, etc. to 
  7. Mike Brennan, brennan@whidbey.com.
  8. ftp site: ftp.whidbey.net in ~/pub/brennan
  9.  
  10. Version 1.3 implements a new internal design for arrays. See file
  11. CHANGES.
  12.  
  13. Version 1.2.2 is best for MsDOS
  14. ---------------------------------------------------------
  15.  
  16. Changes from version 1.1.4 to 1.2:
  17.  
  18. 1) Limit on code size set by #define in sizes.h is gone.
  19.  
  20. 2) A number of obscure bugs have been fixed such as,
  21.    you can now make a recursive function call inside a for( i in A) loop.
  22.    Function calls with array parameters in loop expressions sometimes
  23.    generated erroneous internal code.
  24.  
  25.    See RCS log comments in code for details.
  26.  
  27.    Reported bugs are fixed.
  28.  
  29. 3) new -W options
  30.  
  31.  
  32.    -We file   :  reads commands from file and next argument, regardless
  33.           of form, is ARGV[1].  Useful  for passing -v , -f etc to
  34.           an awk program started with #!/.../mawk
  35.  
  36.  
  37.       #!/usr/local/bin/mawk -We
  38.  
  39.       myprogram -v   works, while
  40.  
  41.       #!/usr/local/bin/mawk -f
  42.  
  43.       myprogram -v    gives error message
  44.       mawk: option -v lacks argument 
  45.  
  46.       This is really a posix bozo.  Posix says you end arguments with
  47.       -- , but this doesn't work with the #! convention.
  48.  
  49.  
  50.  
  51.    -W interactive :  forces stdout to be unbuffered and stdin to
  52.     be line buffered.  Records from stdin are lines regardless of
  53.     the value of RS.  Useful for interaction with a mawk on a pipe.
  54.  
  55.    -W dump, -Wd   :  disassembles internal code to stdout (used to be
  56.        stderr) and exits 0.
  57.  
  58. 4)  FS = "" causes each record to be broken into characters and placed
  59.      into $1,$2 ...
  60.  
  61.      same with split(x,A,"") and split(x,A,//)
  62.  
  63.  
  64. 5)  print > "/dev/stdout"  writes to stdout, exactly the same as
  65.     print
  66.     
  67.     This is useful for passing stdout to
  68.  
  69.     function my_special_output_routine(s, file)
  70.     {
  71.     # do something fancy with s 
  72.     print s > file
  73.     }
  74.  
  75.  
  76. 6) New built-in function fflush() -- copied from the lastest att awk.
  77.  
  78.       fflush() : flushes stdout  and returns 0
  79.       fflush(file)  flushes file and returns 0; if file was not an
  80.       open output file then returns -1.
  81.  
  82. 7)  delete  A ;  -- removes all elements of the array A
  83.  
  84.     intended to replace:
  85.  
  86.      for( i in A) delete A[i] 
  87.  
  88. 8)  mawk errors such as compilation failure, file open failure, etc.
  89.     now exit 2 which reserves exit 1 for the user.
  90.  
  91. 9)  No program now silently exits 0, prior behavior was to exit 2 with
  92.     an error message
  93.