Skip to content

Commit 04f5e14

Browse files
committed
Use standard string-suffix-p.
Use standard string-suffix-p in place of haskell-str-is-suffix-of-p.
1 parent 19a9900 commit 04f5e14

File tree

1 file changed

+0
-11
lines changed

1 file changed

+0
-11
lines changed

haskell-str.el

-11
Original file line numberDiff line numberDiff line change
@@ -51,17 +51,6 @@ Note: The implementation currently only supports ASCII
5151
"Return (up to) N character length prefix of STRING."
5252
(substring string 0 (min (length string) n)))
5353

54-
(defun haskell-str-is-suffix-of-p (str1 str2 &optional ignore-case)
55-
"Return non-nil if STR1 is a suffix of STR2.
56-
If IGNORE-CASE is non-nil, the comparison is done without paying attention
57-
to case differences.
58-
59-
Dual to `haskell-str-is-prefix-of-p'"
60-
(let ((pos (- (length str2) (length str1))))
61-
(if (>= pos 0)
62-
(eq t (compare-strings str1 nil nil
63-
str2 pos nil ignore-case)))))
64-
6554
(defconst haskell-str-literal-encode-ascii-array
6655
[ "\\NUL" "\\SOH" "\\STX" "\\ETX" "\\EOT" "\\ENQ" "\\ACK" "\\a" "\\b" "\\t" "\\n" "\\v" "\\f" "\\r" "\\SO" "\\SI" "\\DLE" "\\DC1" "\\DC2" "\\DC3" "\\DC4" "\\NAK" "\\SYN" "\\ETB" "\\CAN" "\\EM" "\\SUB" "\\ESC" "\\FS" "\\GS" "\\RS" "\\US" " " "!" "\\\"" "#" "$" "%" "&" "'" "(" ")" "*" "+" "," "-" "." "/" "0" "1" "2" "3" "4" "5" "6" "7" "8" "9" ":" ";" "<" "=" ">" "?" "@" "A" "B" "C" "D" "E" "F" "G" "H" "I" "J" "K" "L" "M" "N" "O" "P" "Q" "R" "S" "T" "U" "V" "W" "X" "Y" "Z" "[" "\\\\" "]" "^" "_" "`" "a" "b" "c" "d" "e" "f" "g" "h" "i" "j" "k" "l" "m" "n" "o" "p" "q" "r" "s" "t" "u" "v" "w" "x" "y" "z" "{" "|" "}" "~" "\\DEL" ]
6756
"Array of encodings for 7-bit ASCII character points indexed by ASCII value.")

0 commit comments

Comments
 (0)