Loops no longer executed properly in a browser() session within ESS, when
the loop includes curly braces {}.  This does not happen when using the R
console directly, but happens with both R-3.0.1 and R-2.15.1. See
sessionInfo() and $dpkg -l ess at the end of this message.

> testFun <- function(n){
+    browser()
+    for (i in 1:n)  ##normal
+        print(i)
+    i
+    for (j in 1:n){  ##broken
+        print(j)
+    }
+    j
+    for (k in 1:n){print(k)}
+    k
}
> testFun(3)
Called from: testFun(3)
Browse[1]>
debug at /tmp/ESS-region/test.R@2#3: for (i in 1:n) print(i)
Browse[2]>     for (i in 1:n)  ##normal
+         print(i)
[1] 1
[1] 2
[1] 3
Browse[2]>     i
[1] 3
Browse[2]>     for (j in 1:n){  ##broken
+         print(j)
+     }
debug at /tmp/ESS-region/test.R@2#3: j
Browse[3]>     j
NULL
Browse[3]> for (k in 1:n){print(k)}
debug at /tmp/ESS-region/findDupSamplesPairwise.R@2#3: k
Browse[4]> k
NULL


Browse[4]> sessionInfo()
R version 3.0.1 (2013-05-16)
Platform: x86_64-unknown-linux-gnu (64-bit)

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C
 [3] LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8
 [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8
 [7] LC_PAPER=C                 LC_NAME=C
 [9] LC_ADDRESS=C               LC_TELEPHONE=C
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base

loaded via a namespace (and not attached):
[1] compiler_3.0.1 tools_3.0.1
Browse[4]>

$ dpkg -l ess
Desired=Unknown/Install/Remove/Purge/Hold
|
Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name           Version        Description
+++-==============-==============-============================================
ii  ess            13.05-3precise Emacs mode for statistical programming
and d

	[[alternative HTML version deleted]]

