Pristine Ack-5.5
[Ack-5.5.git] / util / cpp / ch7mon.c
1 /* $Id: ch7mon.c,v 1.5 1994/06/24 10:18:01 ceriel Exp $ */
2 /*
3  * (c) copyright 1987 by the Vrije Universiteit, Amsterdam, The Netherlands.
4  * See the copyright notice in the ACK home directory, in the file "Copyright".
5  */
6 /* EVALUATION OF MONADIC OPERATORS */
7
8 #include        "Lpars.h"
9 #include        <em_arith.h>
10
11 ch7mon(oper, pval)
12         register arith *pval;
13 {
14         switch (oper)   {
15         case '~':
16                 *pval = ~(*pval);
17                 break;
18         case '-':
19                 *pval = -(*pval);
20                 break;
21         case '!':
22                 *pval = !(*pval);
23                 break;
24         }
25 }