~ubuntu-branches/ubuntu/breezy/ratfor/breezy

« back to all changes in this revision

Viewing changes to ratfor.1

  • Committer: Bazaar Package Importer
  • Author(s): Alan Bain
  • Date: 1999-10-26 14:00:00 UTC
  • Revision ID: james.westby@ubuntu.com-19991026140000-328m9rxvjr4gg6ne
Tags: 1.0-7
* Changelog now compressed
* FHS file locations adopted

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
.TH RATFOR 1 "Jun 1996"
 
2
.SH NAME
 
3
ratfor77 \- ratfor preprocessor for Fortran 77
 
4
 
 
5
.SH SYNOPSIS
 
6
.B ratfor 
 
7
.RB [ -l
 
8
.IR n ]
 
9
.RB [ -C ] 
 
10
.RB [ -o
 
11
.IR outputfile ]
 
12
.I filename
 
13
 
 
14
.SH PARAMETERS
 
15
.TP 8
 
16
.BI -l " n"
 
17
Set starting label number.
 
18
.TP 8
 
19
.BI -o " output"
 
20
Specify output file; default is stdout.
 
21
.TP 8
 
22
.B -C
 
23
Keep comments in (useful for compiler directives).
 
24
.TP 8
 
25
.B -?
 
26
Show summary of options.
 
27
 
 
28
.SH DESCRIPTION
 
29
Ratfor has the following syntax:
 
30
 
 
31
prog:   stat
 
32
        prog stat
 
33
 
 
34
stat:   if (...) stat
 
35
        if (...) stat else stat
 
36
        while (...) stat
 
37
        repeat stat
 
38
        repeat stat until (...)
 
39
        for (...;...;...) stat
 
40
        do ... stat
 
41
        switch (intexpr) { case val[,val]: stmt ... default: stmt }
 
42
        break n
 
43
        next n
 
44
        return (...)
 
45
        digits stat
 
46
        { prog }  or  [ prog ]  or  $( prog $)
 
47
        anything unrecognizable
 
48
 
 
49
where stat is any Fortran or Ratfor statement, and intexpr is an
 
50
expression that resolves into an integer value.  A statement is
 
51
terminated by an end-of-line or a semicolon.  The following translations
 
52
are also performed.
 
53
 
 
54
        <       .lt.    <=      .le.
 
55
        ==      .eq.
 
56
        !=      .ne.    ^=      .ne.    ~=      .ne.
 
57
        >=      .ge.    >       .gt.
 
58
        |       .or.    &       .and.
 
59
        !       .not.   ^       .not.   ~       .not.
 
60
 
 
61
Integer constants in bases other that decimal may be specified as
 
62
n%dddd...  where n is a decimal number indicating the base and dddd...
 
63
are digits in that base.  For bases > 10, letters are used for digits
 
64
above 9.  Examples:  8%77, 16%2ff, 2%0010011.  The number is converted
 
65
the equivalent decimal value using multiplication; this may cause sign
 
66
problems if the number has too many digits.
 
67
 
 
68
String literals ("..." or '...') can be continued across line boundaries
 
69
by ending the line to be continued with an underline.  The underline is
 
70
not included as part of the literal.  Leading blanks and tabs on the
 
71
next line are ignored; this facilitates consistent indentation.
 
72
 
 
73
        include file
 
74
 
 
75
will include the named file in the input.
 
76
 
 
77
        define (name,value)     or
 
78
        define name value
 
79
 
 
80
defines name as a symbolic parameter with the indicated value.  Names of
 
81
symbolic parameters may contain letters, digits, periods, and underline
 
82
character but must begin with a letter (e.g.  B.FLAG).  Upper case is
 
83
not equivalent to lower case in parameter names.
 
84
 
 
85
        string name "character string"          or
 
86
        string name(size) "character string"
 
87
 
 
88
defines name to be an integer array long enough to accommodate the ASCII
 
89
codes for the given character string, one per word.  The last word of
 
90
name is initialized to the symbolic parameter EOS, and indicates the end
 
91
of string.
 
92
 
 
93
.SH KEYWORDS
 
94
ratfor fortran preprocessor fortran77 ratfor77 spp
 
95