home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 11 Util / 11-Util.zip / PROTC12A.ZIP / PROTOC.DOC < prev    next >
Text File  |  1990-10-14  |  5KB  |  109 lines

  1.  
  2. PROTOC - A prototype generator for C source code.
  3. Written by Mitchell Fisher - 2/12/90
  4.  
  5. Update: 07/25/90 - Corrected problems with comments on same line
  6.                    as functions as well as a few minor problems with
  7.                    parenthises within a comment.
  8.  
  9.                    BOUND PROTOC so that it will run under OS/2 as well as DOS
  10.  
  11. Update: 10/14/90 - Corrected problem that caused PROTOC not to run under DOS
  12.                    as a BOUND application.
  13.  
  14.  
  15.  
  16. THIS VERSION OF PROTOC IS FREEWARE AND NO CHARGE SHOULD BE ACCEPTED FOR
  17. THIS PRODUCT!!  PLEASE FEEL FREE TO DISTRIBUTE THIS PRODUCT HOWEVER MAKE
  18. SURE THAT THE FOLLOWING FILES EXIST:
  19.  
  20.         PROTOC              - Makefile for Microsoft C
  21.         PROTOC.DOC          - This file
  22.         PROTOC.EXE          - The PROTOC executable for DOS
  23.         CHRFUNCS.OBJ        - Character functions for PROTOC
  24.         PROTOC.C            - C Source code for PROTOC
  25.         PROTOC.H            - Header file of function prototypes for PROTOC
  26.         PROTOC.DEF          - Definition file for Linker for OS/2 not
  27.                               needed for DOS.
  28.  
  29.  
  30.  
  31.  
  32.                                Description:
  33.  
  34. Have you ever been writing a C program and find out you really
  35. need function prototypes.  Well, most of us normally include several .H
  36. files for our code which is made up largely of function prototypes.  If a
  37. funcion is called with a forward reference, then most compilers will
  38. default those calls with an integer type meaning the routines will
  39. return only integers.  Well, this can be a problem if you are working in a
  40. far or huge memory model and you want a far poitner returned from a
  41. function rather than an integer.  However, to take out the drudgery of
  42. going through your code and collecting all the functions and making
  43. prototypes out of them, I wrote this program to do it for you.  It is,
  44. however, based on the Turbo C project file but project files are very
  45. simple to create.  All a project file is is a file that contains a list of
  46. all source code that makes up the program.  If you have just one source
  47. module, sorry, protoc must use a project file so you must enter this one
  48. file into a project file...  For those Turbo C users that use project
  49. files and include .LIB and .OBJ lines in the project, don't wory, PROTOC
  50. will ignore these lines and only process files with the .C extension.
  51. However, there is one thing to watch out for, if PROTOC uses the
  52. project file HELP.PRJ, then the output file will become HELP.H so make
  53. sure there is no .H file that is the same as your project file name.  If
  54. this is the case, just rename the project file to something unique.
  55.  
  56. For a simple useage, enter PROTOC without any parameters.
  57.  
  58. You can redirect PROTOC's output from a file to the screen.  To do this
  59. preceed the project file with a -O.  Example:  PROTOC -O test.prj
  60.  
  61.  
  62.  
  63.                                Commentary:
  64.  
  65. This version, version 1.2, is bundled with the source code.  and is
  66. BOUND so that it will run under OS/2 and DOS.  (I have only tested the
  67. program under OS/2 1.2.)  This source code was originally compiled under
  68. Turbo C Version 2.0 but has been recently been compiler under Microsoft C
  69. Version 5.1 for use with OS/2.
  70.  
  71.   You will also notice a .OBJ file bundled with this package - this file
  72. contains the character functions that PROTOC uses.  The source code for
  73. these functions have not been included.
  74.  
  75. I am pleased to find that people have found this program to be of some
  76. use.  In view of this use, I shall continue to upgrade this program to
  77. work better and faster and provide new options.  Also, a Presentation
  78. Manager version is in the works which will work in OS/2.
  79. This version is free to all you 'C' programmers out there.  With the
  80. advent of ANSI C, this function may prove to be a necessity.
  81.  
  82.  
  83.                         Known limitations or BUGS!
  84.  
  85. This software has been tested rather thouroghly and no MAJOR BUGS have
  86. been found but there is always a possibility so please inform me either by
  87. letter or phone message of any problems and I will try to correct the
  88. problem.
  89.  
  90. One known limitation is that PROTOC will not process a function that has
  91. it's begin and end parenthises on different lines.  This rarely will
  92. happen except for those functions that accept a lot of parameters and the
  93. programmer divides up the function definition into two lines.  If a
  94. function has that many params anyway, the programmer should change it to
  95. use a structure or global variables or whatever.
  96.  
  97.  
  98.  
  99. I hope you find this program of some use.
  100.  
  101.         Mitchell Fisher
  102.         5914 W. Golden Lane
  103.         Glendale, AZ  85302
  104.  
  105.         (602) 435-8723
  106.  
  107.  
  108.  
  109.