Code conforming with the requirements of this standard shall adhere to the following:
Note that conforming code may rely on particular implementation-defined values or features. Also note that the requirements for conforming code and conforming implementations do not require that the results produced by conforming code always be the same when processed by a conforming implementation. The results may be the same, or they may differ.
Conforming code may run in all conforming implementations, but might have allowable implementation-defined behavior that makes it non-portable code. For example, the following are examples of forms that are conforming, but that might return different values in different implementations:
(evenp most-positive-fixnum) → implementation-dependent (random) → implementation-dependent (> lambda-parameters-limit 93) → implementation-dependent (char-name #\A) → implementation-dependent
Use of #+
and #-
does not automatically disqualify a program
from being conforming. A program which uses #+
and #-
is
considered conforming if there is no set of features in which the
program would not be conforming. Of course, conforming programs are
not necessarily working programs. The following program is conforming:
(defun foo () #+ACME (acme:initialize-something) (print 'hello-there))
However, this program might or might not work, depending on whether the
presence of the feature ACME
really implies that a function named
acme:initialize-something
is present in the environment. In effect,
using #+
or #-
in a conforming program means that the variable
*features*
becomes just one more piece of input data to that
program. Like any other data coming into a program, the programmer
is responsible for assuring that the program does not make unwarranted
assumptions on the basis of input data.
Portable code is written using only standard characters.