Fix failure when comparing two S3 objects with incompatible types.
Description of S3 objects now includes base type.
Logical vectors fall back to element-by-element comparison in more cases (#51).
Handle S4 objects that have attributes that are not slots.
Additions are now coloured blue and deletions yellow (instead of the opposite).
compare() now labels output as
new, since that’s the most natural way to use it.
Improvements to comparison display:
Zero length vectors compare robustly (#39)
Line-by-line comparisons show modifications as deletion then addition, rather than addition then deletion (#44).
Differences between numeric vectors are more robust, particularly in the presence of missing values (#43). The number of digits selected has also been slightly improved so that you’re more likely to get exactly the number of digits needed.
Numeric and logical vectors: clearer display of differences. Numbers are right-aligned, and we show the numbers not the differences.
Character vectors: a trailing newline is no longer ignored (#37).
Lists: all elements of the unnamed lists are compared, not just the last! (#32)
Lists: unclassed prior to comparison (#21).
Expression objects: can now be compared (#29).
Calls: srcrefs and attributes are ignored.