aboutsummaryrefslogtreecommitdiff
path: root/sys/vops/achtgen/achtd.x
blob: 6f784749f5e7ac8735cc417222a6740c9c3ebaa7 (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
# Copyright(c) 1986 Association of Universities for Research in Astronomy Inc.

# ACHT_ -- Convert an array of type _ to some other datatype.
# Data types are BUcsilrdx.

procedure achtd (a, b, nelem, ty_b)

double	a[ARB]
char	b[ARB]
int	nelem
int	ty_b

begin
	switch (ty_b) {
	case TY_UBYTE:
	    call achtdb (a, b, nelem)
	case TY_USHORT:
	    call achtdu (a, b, nelem)
	case TY_CHAR:
	    call achtdc (a, b, nelem)
	case TY_SHORT:
	    call achtds (a, b, nelem)
	case TY_INT, TY_POINTER, TY_STRUCT:
	    call achtdi (a, b, nelem)
	case TY_LONG:
	    call achtdl (a, b, nelem)
	case TY_REAL:
	    call achtdr (a, b, nelem)
	case TY_DOUBLE:
	    call achtdd (a, b, nelem)
	case TY_COMPLEX:
	    call achtdx (a, b, nelem)
	}
end