xref: /original-bsd/usr.bin/pascal/libpc/SIN.c (revision 208c3823)
1 /*-
2  * Copyright (c) 1982 The Regents of the University of California.
3  * All rights reserved.
4  *
5  * %sccs.include.redist.c%
6  */
7 
8 #ifndef lint
9 static char sccsid[] = "@(#)SIN.c	1.3 (Berkeley) 04/09/90";
10 #endif /* not lint */
11 
12 #include <math.h>
13 extern int errno;
14 
15 double
16 SIN(value)
17 	double	value;
18 {
19 	double result;
20 
21 	errno = 0;
22 	result = sin(value);
23 	if (errno != 0) {
24 		ERROR("Cannot compute sin(%e)\n", value);
25 	}
26 	return result;
27 }
28