franz/lam7.c
/*
 * (time-string ['x_milliseconds])
 * if given no argument, returns the current time as a string
 * if given an argument which is a fixnum representing the current time
 * as a fixnum, it generates a string from that
 *
 * the format of the string returned is that defined in the Unix manual
 * except the trailing newline is removed.
 *
 */
(time-string ['x_milliseconds])
if given no argument, returns the current time as a string
if given an argument which is a fixnum representing the current time
as a fixnum, it generates a string from that

the format of the string returned is that defined in the Unix manual
except the trailing newline is removed.
( time - string [ ' x_milliseconds ] ) if given no argument returns the current time as a string if given an argument which is a fixnum representing the current time as a fixnum it generates a string from that the format of the string returned is that defined in the Unix manual except the trailing newline is removed .
lispval
Ltymestr()
{
    long timevalue;
    char *retval;
    switch(np-lbot)
    {
	case 0: time(&timevalue);
		break;
	case 1: while (TYPE(lbot[0].val) != INT)
	          lbot[0].val =
		     errorh(Vermisc,"time-string: non fixnum argument ",
		     		nil,TRUE,0,lbot[0].val);
		timevalue = lbot[0].val->i;
		break;
	default:
		argerr("time-string");
    }
    retval = (char *) ctime(&timevalue);
    retval[strlen(retval)-1] = '\0';
    return((lispval) inewstr(retval));
}
lispval Ltymestr ( ) { long timevalue ; char * retval ; switch ( np - lbot ) { case 0 : time ( & timevalue ) ; break ; case 1 : while ( TYPE ( lbot [ 0 ] . val ) != INT ) lbot [ 0 ] . val = errorh ( Vermisc , " " , nil , TRUE , 0 , lbot [ 0 ] . val ) ; timevalue = lbot [ 0 ] . val -> i ; break ; default : argerr ( " " ) ; } retval = ( char * ) ctime ( & timevalue ) ; retval [ strlen ( retval ) - 1 ] = ' \0 ' ; return ( ( lispval ) inewstr ( retval ) ) ; }
(time-string ['x_milliseconds])
 if given no argument, returns the current time as a string
 if given an argument which is a fixnum representing the current time
 as a fixnum, it generates a string from that
( time - string [ ' x_milliseconds ] ) if given no argument returns the current time as a string if given an argument which is a fixnum representing the current time as a fixnum it generates a string from that
/* remove newline character */