[ESS-bugs] ess-mode 16.10 [Released git: e92ed78b8890]; Quoted Comment Character and C-c C-c

Mario Bourgoin mabou at microsoft.com
Tue Nov 21 14:14:03 CET 2017


Hi,

In an R source file, I have the line:

scored <- read.csv(scored_path, comment.char="#")

When I'm on the line and execute ess-eval-region-or-function-or-paragraph-and-step (i.e. C-c C-c), R only receives this:

> scored <- read.csv(scored_path, comment.char="
+

As you see, the function isn't parsing the line correctly: it stops reading at the R comment character even though it is between quotes.

How do I make the function parse the quoted comment char correctly?

If I select the line as a region, then C-c C-c works correctly, which is a workaround but not what I seek. I have searched the fine manual for "comment" but nothing useful came out. And I have searched for "ess-eval-region-or-function-or-paragraph-and-step comment char" but nothing useful came up.

Mario

[ess-site.el]: ess-customize-alist=nil
[ess-site.el _2_]: ess-customize-alist=nil
(R): ess-r-versions-create making M-x defuns for


(R): ess-dialect=nil, buf=*scratch*, start-arg=nil
current-prefix-arg=nil
(inf-ess 1): lang=R, dialect=nil, tmp-dialect=R, buf=*scratch*
(inf-ess 1.1): procname=R temp-dialect=R, buf-name=*R*
(inf-ess 2.0) Method #3 start=c:/Users/mabou/OneDrive - Microsoft/KPMG/ buf=*R*
(ess-setq-vars-LOCAL): language=S, dialect=R, buf=nil, comint..echoes=t, comint..sender=comint-simple-send
(inf-ess 2.1): ess-language=S, ess-dialect=R buf=*R*
(ess-setq-vars-LOCAL): language=S, dialect=R, buf=nil, comint..echoes=t, comint..sender=inferior-ess-input-sender
(i-ess 1): buf=*R*, lang=S, comint..echo=t, comint..sender=inferior-ess-input-sender,
(i-ess end): buf=*R*, lang=S, comint..echo=t, comint..sender=inferior-ess-input-sender,
(inf-ess 3.0): prog=Rterm, start-args=--ess --no-save --no-restore --no-init-file , echoes=t
Making Process...Buf *R*, :Proc R, :Prog Rterm
:Args= --ess --no-save --no-restore --no-init-file
Start File=nil
(inferior-ess: waiting for process to start (before hook)
(inferior-ess 3): waiting for process after hookload-ESSR cmd:
local({
                          source('c:/Program Files/GNU Emacs 25.2/share/emacs/etc/ess/ESSR/R/.load.R', local=TRUE) #define load.ESSR
                          load.ESSR('c:/Program Files/GNU Emacs 25.2/share/emacs/etc/ess/ESSR/R')
                      })

(R): inferior-ess-language-start=options(STERM='iESS', str.dendrogram.last="'", editor='emacsclient.exe', show.error.locations=TRUE)
(ess-setq-vars-LOCAL): language=S, dialect=R, buf=nil, comint..echoes=t, comint..sender=comint-simple-send
(ess-mode-1): ess-language=S, ess-dialect=R buf=Scale.R
(ess-mode-1.5): alist=((inferior-ess-reload-function quote inferior-ess-reload:R) (ess-quit-function quote ess-quit:R) (ess-send-region-function quote ess-send-region:R) (ess-load-file-function quote ess-load-file:R) (ess-build-load-command-function quote ess-build-load-command:R) (ess-build-eval-command-function quote ess-build-eval-command:R) (ess-local-customize-alist quote ess-r-customize-alist) (ess-eldoc-function function ess-R-eldoc-function) (ess-dialect . R) (ess-suffix . R) (ess-ac-sources quote (ac-source-R)) (ess-company-backends quote ((company-R-args company-R-objects :separate))) (ess-build-tags-command . rtags('%s', recursive = TRUE, pattern = '\\.[RrSs](rw)?$',ofile = '%s')) (ess-traceback-command . local({cat(geterrmessage(), "----------------------------------
", fill=TRUE);try(traceback(), silent=TRUE)})
) (ess-call-stack-command . traceback(1)
) (ess-build-eval-message-function function ess-r-build-eval-message) (ess-dump-filename-template ess-replace-regexp-in-string S$ ess-suffix ess-dump-filename-template-proto) (ess-build-help-command-function function ess-r-build-help-command) (ess-help-web-search-command quote ess-R-sos) (ess-mode-syntax-table . ess-r-syntax-table) (ess-mode-completion-syntax-table . ess-r-completion-syntax-table) (ess-mode-editing-alist . R-editing-alist) (ess-change-sp-regexp . ess-R-change-sp-regexp) (ess-help-sec-regex . ess-help-R-sec-regex) (ess-help-sec-keys-alist . ess-help-R-sec-keys-alist) (ess-loop-timeout . ess-S-loop-timeout) (ess-cmd-delay . ess-R-cmd-delay) (ess-function-pattern . ess-R-function-pattern) (ess-object-name-db-file . ess-r-namedb.el) (ess-smart-operators . ess-R-smart-operators) (inferior-ess-program . inferior-R-program-name) (inferior-ess-objects-command . inferior-R-objects-command) (inferior-ess-font-lock-keywords quote inferior-R-font-lock-keywords) (inferior-ess-search-list-command . search()
) (inferior-ess-help-command . inferior-ess-r-help-command) (inferior-ess-help-filetype) (inferior-ess-exit-command . q()) (inferior-ess-exit-prompt . Save workspace image? [y/n/c]: ) (inferior-ess-start-file) (inferior-ess-start-args . ) (inferior-ess-mode-syntax-table . inferior-ess-r-syntax-table) (ess-error-regexp-alist . ess-R-error-regexp-alist) (ess-describe-object-at-point-commands quote ess-R-describe-object-at-point-commands) (ess-STERM . iESS) (ess-editor . R-editor) (ess-pager . R-pager) (prettify-symbols-alist quote ((<- . 8592) (<<- . 8606) (-> . 8594) (->> . 8608))) (font-lock-syntactic-face-function function ess-r-font-lock-syntactic-face-function) (ess-language . S) (inferior-ess-exit-command . q()
) (inferior-ess-language-start eval inferior-S-language-start) (comint-use-prompt-regexp . t) (comint-process-echoes . t) (inferior-ess-primary-prompt . > ) (inferior-ess-secondary-prompt . + ) (comment-start . #) (ess-imenu-generic-expression . ess-imenu-S-generic-expression) (comment-add . 1) (comment-start-skip . #+ *) (comment-use-syntax . t) (comment-column . 40) (ess-no-skip-regexp concat ^ *@\| (default-value (quote ess-no-skip-regexp))) (inferior-ess-prompt . inferior-S-prompt) (ess-get-help-topics-function function ess-s-get-help-topics-function) (ess-getwd-command . getwd()
) (ess-setwd-command . setwd('%s')
) (ess-funargs-command . .ess_funargs("%s")
) (fill-nobreak-predicate quote ess-inside-string-p) (normal-auto-fill-function quote ess-do-auto-fill) (ess-execute-screen-options-command . options(width=%d, length=99999)
))
(ess-mode-1.6): editing-alist=((paragraph-start concat \s-*$\| page-delimiter) (paragraph-separate concat \s-*$\| page-delimiter) (paragraph-ignore-fill-prefix . t) (require-final-newline . mode-require-final-newline) (indent-line-function quote ess-indent-line) (parse-sexp-ignore-comments . t) (ess-style . ess-default-style) (ess-mode-syntax-table . ess-r-syntax-table) (add-log-current-defun-header-regexp . ^\(.+\)\s-+<-[
]*function) (ess-font-lock-keywords quote ess-R-font-lock-keywords) (ess-font-lock-defaults ess--extract-default-fl-keywords ess-R-font-lock-keywords) (font-lock-defaults quote (ess-font-lock-defaults nil nil ((46 . w) (95 . w)))))
(ess-setq-vars-LOCAL): language=S, dialect=R, buf=nil, comint..echoes=t, comint..sender=comint-simple-send

Finished setting up ESS-mode.
ess-request-a-process: {beginning}
ess-BEG-of-fun after 'search-FWD (': Ini-pt 63, (p)-Ini-pt = 9
ELSE  not in setMethod() header ...
ess-BEG-of-fun after 'search-FWD (': Ini-pt 551, (p)-Ini-pt = 25
ELSE  not in setMethod() header ...
ess-BEG-of-fun after 'search-FWD (': Ini-pt 667, (p)-Ini-pt = 26
ELSE  not in setMethod() header ...
ess-BEG-of-fun after 'search-FWD (': Ini-pt 785, (p)-Ini-pt = 24
ELSE  not in setMethod() header ...
ess-BEG-of-fun after 'search-FWD (': Ini-pt 870, (p)-Ini-pt = 27
ELSE  not in setMethod() header ...
ess-BEG-of-fun after 'search-FWD (': Ini-pt 734, (p)-Ini-pt = 20
ELSE  not in setMethod() header ...
ess-BEG-of-fun after 'search-FWD (': Ini-pt 785, (p)-Ini-pt = 24
ELSE  not in setMethod() header ...
ess-BEG-of-fun after 'search-FWD (': Ini-pt 870, (p)-Ini-pt = 27
ELSE  not in setMethod() header ...


Emacs  : GNU Emacs 25.2.1 (x86_64-w64-mingw32)
of 2017-04-24
Package: ess-mode 16.10 [Released git: e92ed78b8890]

current state:
==============
(setq
ess-language "S"
ess-dialect "R"
ess-ask-for-ess-directory t
ess-ask-about-transfile nil
ess-directory "~/OneDrive - Microsoft/Work Folders/Project"
ess-keep-dump-files "always"
ess-source-directory "C:\\Users\\mabou\\AppData\\Local\\Temp"
ess-use-ido t
ess-use-eldoc t
ess-use-tracebug t
ess-use-auto-complete t
ess-use-company t
ess-eval-visibly-p t
ess-can-eval-in-background t
ess-local-process-name "R"
)

	[[alternative HTML version deleted]]



More information about the ESS-bugs mailing list