* Copyright (c) 1980 The Regents of the University of California.
* %sccs.include.redist.c%
static char sccsid
[] = "@(#)fdec.c 5.3 (Berkeley) %G%";
* pxp - Pascal execution profiler
* Version 1.2 January 1979
* Program, procedure or function "header", i.e.:
optstk
['z'-'a'] |= opts
['z'-'a'];
if (nojunk
&& !inpflist(r
[2]))
if (r
[0] == T_PROG
&& noinclude
&& bracket
)
if (noblank(setline(r
[1])))
ppid("{identifier list}");
if (rl
[1][0] != T_PPROC
) {
if (r
[0] == T_FDEC
&& r
[4] != NIL
) {
* Forward declaration i.e. the second line of
* procedure fum(var i: integer);
* The "body" of a procedure, function, or program declaration,
* i.e. a non-forward definition encounter.
* The guts of the procedure, function or program, i.e.
* the part between the begin and the end.
funcend(fp
, bundle
, binfo
)
if (cbn
== 1 && noinclude
&& bracket
)
if (noblank(setline(bundle
[1])) && lastbn
> cbn
)
if (putcml() == 0 && lastbn
> cbn
)
ppsep(cbn
== 1 ? "." : ";");
opts
['z'-'a'] = optstk
['z'-'a'] & 1;
* Segend is called at the end of a routine segment (a separately
* compiled segment that is not the main program). Since pxp only works
* with a single pascal file, this routine should never be called.
error("Missing program statement and program body");
* External declaration i.e. the second line of
* procedure fum(var i: integer);