update packages
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
;;; -*- lexical-binding: t -*-
|
||||
(require 'yasnippet)
|
||||
|
||||
;; whitespace removing functions from Magnar Sveen ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
@@ -28,9 +29,17 @@
|
||||
"This function returns `comment-start' trimmed by whitespaces."
|
||||
(yas-s-trim comment-start))
|
||||
|
||||
(defun yas-trimmed-add-comment ()
|
||||
"This function returns `comment-start' trimmed by whitespaces. It uses
|
||||
`comment-add' to determine how many comment symbols to insert."
|
||||
(yas-s-trim (apply #'concat (mapcar (lambda (x)
|
||||
comment-start)
|
||||
(number-sequence 0 comment-add)))))
|
||||
|
||||
(defun yas-trimmed-comment-end ()
|
||||
"This function returns `comment-end' trimmed by whitespaces if `comment-end' is not empty.
|
||||
Otherwise the reversed output of function `yas-trimmed-comment-start' is returned."
|
||||
"This function returns `comment-end' trimmed by whitespaces if
|
||||
`comment-end' is not empty. Otherwise the reversed output of
|
||||
function `yas-trimmed-comment-start' is returned."
|
||||
(if (eq (length comment-end) 0)
|
||||
(yas-string-reverse (yas-trimmed-comment-start))
|
||||
(yas-s-trim comment-end)))
|
||||
|
||||
Reference in New Issue
Block a user