[ESS] R-mode: forward-sexp: Scan error: "Unbalanced parentheses"

Aleksandar Blagotić aca.blagotic at gmail.com
Tue Dec 6 02:18:37 CET 2011


Hm, that is strange... maybe it has something to do with Arch Linux
packages. I'll investigate this one further and report back.

Thanks,

aL3xa



On Tue, Dec 6, 2011 at 02:08, Michael Hannon <jm_hannon at yahoo.com> wrote:
>
> > Let's presuppose that I have a function like this:
> >
> > fn <- function(x, ...){
> >   re <- "^#{1,6} [[:print:]]+$"
> >   grepl(re, x, ...)
> > }
> >
> > As soon as I put my cursor at the end of the line with regexp, and
> > press RET, I get this error:
> >
> > forward-sexp: Scan error: "Unbalanced parentheses"
> >
> > I cannot indent the line with regex, and error comes up, though I've
> > provided a valid R regular expression. Sometimes it hogs Emacs and I
> > need to kill -s 9 it. =/
> > Any ideas how to mend this?
> > (I'm using  Emacs 23.3.1 with ESS grabbed from SVN repos)
>
> Hi, Aleksandar.  I don't have a solution to your problem, but it appears that I
> don't have the problem on my system.  Please see the appended for details.
>
> Do I have the details correct?
>
> -- Mike
>
> Emacs  : GNU Emacs 23.3.1 (x86_64-redhat-linux-gnu, GTK+ Version 2.24.7)
>  of 2011-11-23 on x86-16.phx2.fedoraproject.org
> Package: ess-mode 5.14
>
> > x <- "foobar"
> > y <- "### abc"
> > fn <- function(x, ...){
> +   re <- "^#{1,6} [[:print:]]+$"
> +   grepl(re, x, ...)
> + }
> > fn(x)
> [1] FALSE
> > fn(y)
> [1] TRUE



More information about the ESS-help mailing list