Number Input Correction
Heh! I just spotted a shortcoming in the American date reader. Should add 2000 to the 2-digit year value:(defun convert-american-short-date (s)
;; mm/dd/yy
(multiple-value-bind (start end gstart gend)
(#~m%^([0-9][0-9]?)/([0-9][0-9]?)/([0-9][0-9]?)$% s)
(declare (ignore end))
(when start
(symbol-macrolet
((ystart (aref gstart 2))
(yend (aref gend 2))
(mstart (aref gstart 0))
(mend (aref gend 0))
(dstart (aref gstart 1))
(dend (aref gend 1)))
(ignore-errors
(let* ((yyyy (+ 2000 (read-from-string (subseq s ystart yend))))
(mm (read-from-string (subseq s mstart mend)))
(dd (read-from-string (subseq s dstart dend))))
(encode-universal-time 0 0 0 dd mm yyyy)
))))))
Dr. David McClain
Chief Technical Officer
Refined Audiometrics Laboratory
4391 N. Camino Ferreo
Tucson, AZ 85750
email: dbm@refined-audiometrics.com
phone: 1.520.390.3995