File tree Expand file tree Collapse file tree 3 files changed +6
-11
lines changed Expand file tree Collapse file tree 3 files changed +6
-11
lines changed Original file line number Diff line number Diff line change 91
91
(require 'purescript-vars )
92
92
(require 'purescript-string )
93
93
(require 'cl-lib )
94
+ (eval-when-compile
95
+ (when (< emacs-major-version 28 )
96
+ (require 'subr-x )))
94
97
95
98
(defgroup purescript-indent nil
96
99
" PureScript indentation."
@@ -655,8 +658,8 @@ symbols in the sexp."
655
658
(string-match " where[ \t ]*" purescript-indent-current-line-first-ident))
656
659
(diff-first ; not a function def with the same name
657
660
(or (null valname-string)
658
- (not (string= (purescript -trim valname-string)
659
- (purescript -trim purescript-indent-current-line-first-ident)))))
661
+ (not (string= (string -trim valname-string)
662
+ (string -trim purescript-indent-current-line-first-ident)))))
660
663
661
664
; ; (is-type-def
662
665
; ; (and rpurs-sign (eq (char-after rpurs-sign) ?\:)))
Original file line number Diff line number Diff line change @@ -439,7 +439,7 @@ Brings up the documentation for purescript-mode-hook."
439
439
(message " %s "
440
440
(concat (car lines)
441
441
(if (and (cdr lines) (stringp (cadr lines)))
442
- (format " [ %s .. ] " (purescript-string-take (purescript -trim (cadr lines)) 10 ))
442
+ (format " [ %s .. ] " (purescript-string-take (string -trim (cadr lines)) 10 ))
443
443
" " ))))))
444
444
445
445
(defun purescript-current-line-string ()
Original file line number Diff line number Diff line change 1
1
; ;; purescript-string.el --- string manipulation utilties -*- lexical-binding : t -*-
2
- ;;;### autoload
3
- (defun purescript-trim (string )
4
- (replace-regexp-in-string
5
- " ^[ \t\n ]+" " "
6
- (replace-regexp-in-string
7
- " [ \t\n ]+$" " "
8
- string)))
9
-
10
2
;;;### autoload
11
3
(defun purescript-string-take (string n )
12
4
" Take n chars from string."
You can’t perform that action at this time.
0 commit comments