[Rd] "a.matrix[a.char.matrix]<- " crashes R (PR#447)
Fri, 18 Feb 2000 17:05:50 +0100 (MET)
Peter Dalgaard BSA <firstname.lastname@example.org> writes:
> Still crashes for me!
[Directed back to R-bugs, and please keep it there!]
OK, there are two issues here:
(a) matrix subscripting doesn't work with character type. Plain and
simple. A matrix subscript just get flattened into a character vector
and then used for subscripting. We might want to give an error instead
or simply implement the expected behaviour, but not this close to a
major release, I think. (Splus cant do this either)
(b) There's a bug in string indexing:
Program received signal SIGSEGV, Segmentation fault. <etc>
It seems to happen only when there are repeated indices. The bug is
that the names component of x which is originally empty isn't filled
with "" for the first elements as it usually is but has NULL (0x0)
Will dig deeper...
O__ ---- Peter Dalgaard Blegdamsvej 3
c/ /'_ --- Dept. of Biostatistics 2200 Cph. N
(*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918
~~~~~~~~~~ - (email@example.com) FAX: (+45) 35327907
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: firstname.lastname@example.org