Skip to content

Commit ace711a

Browse files
committed
Enable lexical binding in stata files
Remove ess-eval-linewise-function reference, which no longer exists. Also remove stata-eval-linewise (and ess-sta-delimiter-friendly), which doesn't seem to do anything.
1 parent c62a9d7 commit ace711a

File tree

2 files changed

+3
-13
lines changed

2 files changed

+3
-13
lines changed

lisp/ess-stata-lang.el

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
;;; ess-stata-lang.el --- Stata customization
1+
;;; ess-stata-lang.el --- Stata customization -*- lexical-binding: t; -*-
22

33
;; Copyright (C) 1999--2000, Thomas Lumley, A. J. Rossini, Brendan Halpin.
44
;; Copyright (C) 1997--2004 A.J. Rossini, Richard M. Heiberger, Martin

lisp/ess-stata-mode.el

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
;;; ess-stata-mode.el --- Stata customization
1+
;;; ess-stata-mode.el --- Stata customization -*- lexical-binding: t; -*-
22

33
;; Copyright (C) 1997--1999 A. J. Rossini, Thomas Lumley
44
;; Copyright (C) 1997--2004 A.J. Rossini, Richard M. Heiberger, Martin
@@ -72,7 +72,6 @@
7272
(ess-loop-timeout . 500000 )
7373
(ess-object-name-db-file . "ess-sta-namedb.el" )
7474
(ess-help-web-search-command . "https://www.stata.com/search/?q=%s&restrict=&btnG=Search&client=stata&num=&output=xml_no_dtd&site=stata&ie=&oe=UTF-8&sort=&proxystylesheet=stata")
75-
(ess-eval-linewise-function . #'stata-eval-linewise)
7675
(inferior-ess-program . inferior-STA-program)
7776
(inferior-ess-objects-command . "describe\n")
7877
(inferior-ess-help-command . "help %s\n") ;; assumes set more off
@@ -202,20 +201,11 @@ This function is placed in `ess-presend-filter-functions'."
202201

203202
(cl-defmethod ess-help-get-topics (proc &context (ess-dialect "stata"))
204203
"Return a list of current STA help topics associated with process PROC."
205-
(or (ess-process-get 'help-topics)
204+
(or (ess-process-get 'help-topics proc)
206205
(progn
207206
(ess-process-put 'help-topics (ess--STA-retrive-topics-from-search))
208207
(ess-process-get 'help-topics))))
209208

210-
(defun stata-eval-linewise (text &optional invisibly &rest args)
211-
;; The following is required to make sure things work!
212-
(let ((ess-eval-linewise-function nil)
213-
;; RAS: mindless replacement of semi-colons
214-
(text (if ess-sta-delimiter-friendly
215-
(ess-replace-in-string text ";" "\n")
216-
text)))
217-
(apply #'ess-eval-linewise text t args)))
218-
219209
(provide 'ess-stata-mode)
220210

221211
;;; ess-stata-mode.el ends here

0 commit comments

Comments
 (0)