aboutsummaryrefslogtreecommitdiff
path: root/unix/boot/spp/rpp/rpprat/poicod.r
blob: 7b31bf80ad1c4250d3fa85cd3bd1d6e7f51c0243 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
include defs

# POICOD -- Called to process a declaration of type "pointer".

subroutine poicod (declare_variable)

integer	declare_variable
include COMMON_BLOCKS
string	spointer XPOINTER

# Fortran declarations for the MEM common.
string	p1	"logical Memb(1)"
string	p2	"integer*2 Memc(1)"
string	p3	"integer*2 Mems(1)"
string	p4	"integer Memi(1)"
string	p5	"integer Meml(1)"
string	p6	"real Memr(1)"
string	p7	"double precision Memd(1)"
string	p8	"complex Memx(1)"
string	p9	"equivalence (Memb, Memc, Mems, Memi, Meml, Memr, Memd, Memx)"
string	pa	"common /Mem/ Memd"

	# Output declarations only once per procedure declarations section.
	# The flag memflg is cleared when processing of a procedure begins.

	if (memflg == NO) {
	    call poidec (p1)
	    call poidec (p2)
	    call poidec (p3)
	    call poidec (p4)
	    call poidec (p5)
	    call poidec (p6)
	    call poidec (p7)
	    call poidec (p8)
	    call poidec (p9)
	    call poidec (pa)
	    memflg = YES
	}

	if (declare_variable == YES) {
	    call outtab
	    call outstr (spointer)
	}
end


# POIDEC -- Output a poicod declaration statement.

subroutine poidec (str)

character str

	call outtab
	call outstr (str)
	call outdon
end