franz/fex1.c
/* (errset form [flag])  
   if present, flag determines if the error message will be printed
   if an error reaches the errset.
   if no error occurs, errset returns a list of one element, the 
    value returned from form.
   if an error occurs, nil is usually returned although it could
    be non nil if err threw a non nil value 
 */
(errset form [flag])
if present, flag determines if the error message will be printed
if an error reaches the errset.
if no error occurs, errset returns a list of one element, the
value returned from form.
if an error occurs, nil is usually returned although it could
be non nil if err threw a non nil value
( errset form [ flag ] ) if present flag determines if the error message will be printed if an error reaches the errset . if no error occurs errset returns a list of one element the value returned from form . if an error occurs nil is usually returned although it could be non nil if err threw a non nil value
lispval Nerrset()
{
	lispval temp,flag;
	pbuf pb;
	Savestack(0);
	if(TYPE(lbot->val) != DTPR) return(nil);	
	flag = lbot->val->d.cdr;
	if(TYPE(flag) == DTPR) flag = eval(flag->d.car); 
	else flag = tatom; 	
	protect(flag);
	errp = Pushframe(F_CATCH,Verall,flag);
	switch(retval) {
	case C_THROW: 	
			break;
	case C_INITIAL:	
			temp = eval(lbot->val->d.car);
			protect(temp);
			(lispretval = newdot())->d.car = temp;
			break;
	}
	errp = Popframe();
	Restorestack();
	return(lispretval);
}
lispval Nerrset ( ) { lispval temp , flag ; pbuf pb ; Savestack ( 0 ) ; if ( TYPE ( lbot -> val ) != DTPR ) return ( nil ) ; flag = lbot -> val -> d . cdr ; if ( TYPE ( flag ) == DTPR ) flag = eval ( flag -> d . car ) ; else flag = tatom ; protect ( flag ) ; errp = Pushframe ( F_CATCH , Verall , flag ) ; switch ( retval ) { case C_THROW : break ; case C_INITIAL : temp = eval ( lbot -> val -> d . car ) ; protect ( temp ) ; ( lispretval = newdot ( ) ) -> d . car = temp ; break ; } errp = Popframe ( ) ; Restorestack ( ) ; return ( lispretval ) ; }
(errset form [flag])
if present, flag determines if the error message will be printed
if an error reaches the errset.
( errset form [ flag ] ) if present flag determines if the error message will be printed if an error reaches the errset .
/* no form */ /* evaluate and save flag first */ /* if not present , assume t */ /*
			 * error thrown to this routine, value thrown is
			 * in lispretval
			 */ /*
			 * normally just evaluate expression and listify it.
			 */