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

Questions about COERCE



Are the following examples of calls to COERCE legal, illegal, or permissible
but not required extensions?  The manual isn't very explicit on this point.

  (coerce '(1 2 3) '(vector t 3))	;length specified
  (coerce '(1 2 3) '(vector t 4))	;length specified and doesn't match
  (coerce x '(array single-float 2))	;not a subtype of sequence
  (coerce #\A 'string-char)		;subtype of character
  (coerce #\c-A 'string-char)		;type mismatch: error or discard bits?
  (coerce 22/7 '(float 0 10))		;range specified

Currently each of these expressions signals an error in our implementation,
although none of them would be difficult to implement if I knew what they
were supposed to do.  It's okay with me to leave them illegal.