Christophe
Weblog
Wiki
Code
Publications
Music
projects
/
swankr.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
more srcref frobbing
[swankr.git]
/
swank.R
diff --git
a/swank.R
b/swank.R
index 757e2430752b00ce87724f82ccfbd0d6dfbb5dbe..8ba9060f6147a47956ba4e6e18a8d4a8ebd9be45 100644
(file)
--- a/
swank.R
+++ b/
swank.R
@@
-525,6
+525,12
@@
computeRestartsForEmacs <- function (sldbState) {
if(mode(s) == "name") {
return(s)
}
if(mode(s) == "name") {
return(s)
}
+ if(is(s, "srcref")) {
+ ## more monumental KLUDGE: parsing (in 2.14, at least) appears
+ ## to put srcrefs directly in `length 2' objects, which we need
+ ## to frob directly.
+ return(frob(list(s))[[1]])
+ }
srcrefs <- attr(s, "srcref")
attribs <- attributes(s)
new <-
srcrefs <- attr(s, "srcref")
attribs <- attributes(s)
new <-
@@
-536,6
+542,9
@@
computeRestartsForEmacs <- function (sldbState) {
if(!is.null(attr(s, "srcref"))) {
attr(new, "srcref") <- frob(srcrefs)
}
if(!is.null(attr(s, "srcref"))) {
attr(new, "srcref") <- frob(srcrefs)
}
+ if(!is.null(attr(s, "wholeSrcref"))) {
+ attr(new, "wholeSrcref") <- frob(list(attr(s, "wholeSrcref")))[[1]]
+ }
new
}
withRestarts({
new
}
withRestarts({