Rand is a special case of proc, and (for either) if the switch comp is on (and the compiler is available) then the generated procedure body is compiled.
Rand with a single argument and proc both return as their
values anonymous procedures, which if they are not compiled are Lisp
lambda expressions. However, if compilation is in effect then they
return only an identifier that has no external significance
but which can be applied as a function in the same way as a lambda
expression.
It is primarily intended that such ``proc expressions'' will be used immediately as input to randpoly. The algebraic processor is not intended to handle lambda expressions. However, they can be output or assigned to variables in algebraic mode, although the output form looks a little strange and is probably best not displayed. But beware that lambda expressions cannot be evaluated by the algebraic processor (at least, not without declaring some internal Lisp functions to be algebraic operators). Therefore, for testing purposes or curious users, this package provides the operators showproc and evalproc respectively to display and evaluate ``proc expressions'' output by rand or proc (or in fact any lambda expression), in the case of showproc provided they are not compiled.
see also: REDUCE Home Page