home *** CD-ROM | disk | FTP | other *** search
/ Oakland CPM Archive / oakcpm.iso / cpm / pascal-p / pp319doc.lbr / SOURCE.MZN / SOURCE.MAN
Encoding:
Text File  |  1987-02-03  |  4.1 KB  |  77 lines

  1. .macro chttl = Program File Preparation
  2. .ch .chttl
  3. .hl 1 Line Numbers and Line Length
  4. .bb Source files for Pascal-P are normally variable line length Ascii files, 
  5. with or without FRONT numbering (described below). .eb  By default any
  6. characters past the first 80 of a line are ignored,  and treated as
  7. comments. 
  8.  
  9. Source  lines  containing  an initial string of  8  digits  are
  10. treated  as numbered,  and the line numbers retained and processed by the 
  11. compiler.   These 8 digits are not included in the 80 
  12. (or other,  see w  compiler
  13. option)  character line length limitation.   The compiler assigns sequential
  14. line numbers to un-numbered source (but see _$include below).
  15.  
  16. .hl 1 Indentation coding
  17. Source  files may use data compression for indentation,  consisting of an
  18. initial  "DLE"  (chr(16)) followed by  the printing character  chr(ord(' ')  +
  19. indentation_count).   This both compresses source code storage,  and speeds up
  20. compilation  by  eliminating  scanning of  unnecessary  blanks.   The  utility
  21. programs  "EXPAND" and "COMPRESS" can be used to control this formatting. 
  22. The above line length limitation applies to the expanded source line.
  23.  
  24. .hl 1 Comments
  25. Comments follow the standard Pascal conventions using either (* and *) or
  26. {  and } as delimiters.   Note that "(*" cannot be terminated by "}",  nor can
  27. "{"  be  terminated  by "*)".   This is a deliberate deviation  from  the  ISO
  28. standard.
  29.  
  30. .hl 1 File inclusion
  31. A  line  beginning (at the extreme left,  apart from  line  number)  with
  32. "$include filename" causes that file to be included in the compilation at that
  33. point.  The remainder of the line is listed but ignored.  If the included file
  34. is  unnumbered further line numbers are assigned at the next multiple of  1000
  35. plus 1.  
  36.  
  37. The "i" compiler option, (See compiler options) avoids the line number control
  38. and may be combined with other options on the same line.  
  39.  
  40. At present the master file and two (2) levels of inclusion are available.
  41.  
  42. .hl 1 Characters and Identifiers
  43. The compiler recognizes both UPPER and lower case letters.  
  44. A tab character  is treated as a space,  but listed as a tab char. .bb A tab
  45. is considered a single character in evaluating line length.  .eb
  46. The compiler considers
  47. names which differ only in the case of letters to be identical.  The  underbar
  48. character  "__"  is  considered to be alphabetic in names. Only the first  8
  49. characters  of names are significant,  although reserved words are checked for
  50. exact spelling.   Thus "procedur" and "procedure" are distinct, but "procedur"
  51. and  "procedures"  are  not distinct.   The 8  character  names  are  retained
  52. throughout any linking/loading processes which may follow.  However non-global
  53. procedures use compiler assigned unique names, rather than user names, thus
  54. avoiding name collisions in any following assembly and linkage operations.
  55.  
  56. .hl 1 Integers and Sets
  57. Integers are currently limited to the range -32768..32767, although 32768
  58. may  not be used as a constant in a source program.   Sets are limited to  the
  59. range 0..127.  This allows the complete ASCII character set.
  60.  
  61. .hl 1 Editors
  62. The  CP/m based systems are completely compatible with source files  
  63. prepared by .bb most editors (but do not use Wordstar under the "D" option,
  64. use the "N" option), .eb and with files prepared by the
  65. various UCSD editors.  The significant line termination character is the _<CR>,
  66. and _<LF> is ignored.  Line indentation coding is identical to that of the UCSD
  67. system,  but is controlled by application programs, and thus not forced.  Note
  68. that source files must not have the eighth bit set in characters, and must not
  69. contain non-printing characters outside of dle, cr, lf and tab.
  70. .note CAUTION
  71. For efficiency reasons the compiler (and many other  utilities)
  72. do not check for EOF except after EOLN.   Files with EOF in unterminated lines
  73. are illegal according to the various Pascal standards, and will cause run-time
  74. errors.  Thus source files should always be terminated by a final end-of-line.
  75. WordStar users should especially note this, and not inject a final space.
  76. .res
  77. åy