File: scala-mode-lib.el

package info (click to toggle)
scala-mode-el 1%3A1.1.0-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 288 kB
  • sloc: lisp: 2,527; makefile: 40
file content (26 lines) | stat: -rw-r--r-- 678 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
;;; scala-mode-lib.el - Major mode for editing scala, common functions
;;; Copyright (c) 2012 Heikki Vesalainen
;;; For information on the License, see the LICENSE file

(defvar scala-mode:debug-messages
  "If true, some debug messages may be printed printed."
  nil)

(defmacro scala-lib:column-after (&rest body)
  `(save-excursion
     ,@body
     (current-column)))

(defmacro scala-lib:point-after (&rest body)
  `(save-excursion
     ,@body
     (point)))

(defun scala-lib:delete-trailing-whitespace ()
  (save-excursion
    (end-of-line)
    (skip-syntax-backward " ")
    (unless (bolp)
      (delete-char (- (line-end-position) (point))))))

(provide 'scala-mode-lib)