[Rd] infinite loop in abbreviate() (PR#4564)

tlumley at u.washington.edu tlumley at u.washington.edu
Mon Oct 13 20:15:50 MEST 2003

abbreviate() will go into an infinite loop if two elements of the argument
differ only by leading space

  abbreviate(c("A"," A"), 4)

This is in R 1.8.0 (both OS X and Linux).

The problem appears to be that duplicates are removed before leading and
trailing spaces.


More information about the R-devel mailing list