[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]


>>>>> On Thu, 22 Apr 93 20:04:12 -0400, kevin@freya.cs.umass.edu said:

kevin> A better way to do this is to shadow the symbol DIRECTORY in your
kevin> package so that any changes you make to its behaviour will only be
kevin> seen by your program.  E.g.,

kevin>   (in-package :my-package)
kevin>   (eval-when (compile load eval)
kevin>     (shadow 'directory))

kevin>   (defun directory (&rest args)
kevin>     (sort (apply #'cl:directory args) #'string-lessp
kevin>          :key #'file-namestring))

Another way would be to add a :sort-by clause to #'directory, with possible
arguments :name :size :date etc. Although it's possibly too late for X3J13 to do
this. I don't know whether Franz is willing to alter this locally within ACL,
although my X3J13 specs of 9-APR-92 say that an implementation is allowed to add
such keyword args.