1994-06-24 11:31:16 +00:00
|
|
|
/* $Id$ */
|
1987-03-09 19:15:41 +00:00
|
|
|
/*
|
|
|
|
* (c) copyright 1987 by the Vrije Universiteit, Amsterdam, The Netherlands.
|
|
|
|
* See the copyright notice in the ACK home directory, in the file "Copyright".
|
|
|
|
*/
|
1987-01-06 15:16:53 +00:00
|
|
|
/* EVALUATION OF MONADIC OPERATORS */
|
|
|
|
|
|
|
|
#include "Lpars.h"
|
1987-08-19 10:36:37 +00:00
|
|
|
#include <em_arith.h>
|
1987-01-06 15:16:53 +00:00
|
|
|
|
|
|
|
ch7mon(oper, pval)
|
1987-08-19 10:36:37 +00:00
|
|
|
register arith *pval;
|
1987-01-06 15:16:53 +00:00
|
|
|
{
|
|
|
|
switch (oper) {
|
|
|
|
case '~':
|
|
|
|
*pval = ~(*pval);
|
|
|
|
break;
|
|
|
|
case '-':
|
|
|
|
*pval = -(*pval);
|
|
|
|
break;
|
|
|
|
case '!':
|
|
|
|
*pval = !(*pval);
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
}
|