Next: , Previous: , Up: iklib records   [Index]


6.19.7 Comparison procedure for records

A record–type’s comparison procedure is a function accepting as arguments two instances of a record–type; the return value is: -1, 0, or +1 if the first object precedes the second, is equal to the second, or follows the second, respectively.

Function: record-type-comparison-procedure-set! rtd compar-proc

Select the procedure compar-proc as comparison procedure for records of type rtd; if compar-proc is #f, instances of type rtd make use of the built–in Scheme objects comparison procedure.

Function: record-type-comparison-procedure rtd

Return the function set as custom comparison procedure for records of type rtd; return #f if rtd has no custom comparison procedure.

Function: record-comparison-procedure record

Return #f or the function being the custom comparison procedure for the record record.