home *** CD-ROM | disk | FTP | other *** search
/ ftp.alaska-software.com / 2014.06.ftp.alaska-software.com.tar / ftp.alaska-software.com / acsn / DecMemV.txt < prev    next >
Text File  |  2000-01-02  |  2KB  |  65 lines

  1. DeclareMemvar is an ACSN tool that helps in converting
  2. old CA-Clipper code to Xbase++ style code, that is
  3. that you can compile with /w without getting the
  4. following warning messages:
  5.  
  6.   XBT0102: Ambiguous variable reference
  7.   XBT0103: Ambiguous variable reference, assuming MEMVAR.
  8.  
  9. NOTE: This file only helps in compiling you
  10.       applications so these warning messages will be
  11.       resolved. It's up to you to change these
  12.       variables to either FIELD, LOCAL or STATIC.
  13.  
  14. This program requires Alaska Xbase++ version 1.3
  15. ('Service Release 2') or higher.
  16.  
  17.  
  18. What does the program do?
  19. -------------------------
  20. The program assumes you want to compile the source
  21. files in the current directory. First, it renames all
  22. existing .obj files to .obk. This is because compiling
  23. with /s together with /w does not produce the expected
  24. result.
  25.  
  26. Next, it tries to compile all .prg files in the
  27. current directory. Note that for the best result, your
  28. source code should be error free! DeclareMemvar then
  29. directs all compiler output to the file
  30. Declarememvar.out. This file will be scanned for the
  31. two warning messages
  32.  
  33.   XBT0102: Ambiguous variable reference <variable name> and
  34.   XBT0103: Ambiguous variable reference, assuming MEMVAR <variable name>
  35.  
  36. The <variable name> portion is taken out of the line
  37. and put in an array. Next, a header file called
  38. DeclareMemvar.ch is created. This include file will
  39. contain all <variable name> lines uniquely, in the
  40. format MEMVAR <variable name>.
  41.  
  42. Now all you need to do is to include DeclareMemvar.ch
  43. in you source files like this:
  44.   #include "DeclareMemvar.ch"
  45.  
  46. Now you can compile your programs with /w, but you
  47. don't get ambiguous variable warning messages! You
  48. have a good insight in the variables used in your
  49. application, and can concentrate on how to bring these
  50. variables to either FIELD, LOCAL or STATIC, or even to
  51. objects.
  52.  
  53. Finally all created .obj files are deleted. The .obk
  54. files will be renamed to .obj again. The .out file
  55. will be erased as well.
  56.  
  57. I hope you have some nasty old Summer'87 style source
  58. code files at your disposal to test the program!
  59.  
  60. Regards,
  61. Arno.
  62.  
  63. atolmeijer@tomorrows-world.nl
  64. http://www.tomorrows-world.nl
  65.