Commit e8c97a05 authored by David Byers's avatar David Byers
Browse files

Bug fixes to non-MULE compatibility code

parent 6a3bf133
1999-12-01 David Byers <davby@ida.liu.se>
* compatibility.el (decode-coding-string, encode-coding-string):
Copy the string using copy-sequence to really emulate the real
thing.
* utilities.el (lyskom-string=): Works even if an argument is
nil.
Thu Nov 25 17:05:19 1999 David Byers <davby@sen2.ida.liu.se>
* Release av 0.46-BETA-C p riktigt
......
......@@ -301,8 +301,8 @@ string to search in."
(lyskom-provide-function set-process-coding-system (proc &optional encoding decoding)
)
(lyskom-provide-function encode-coding-string (str coding-system) str)
(lyskom-provide-function decode-coding-string (str coding-system) str)
(lyskom-provide-function encode-coding-string (str coding-system) (copy-sequence str))
(lyskom-provide-function decode-coding-string (str coding-system) (copy-sequence str))
(lyskom-provide-function string-bytes (str) (length str))
(lyskom-provide-function check-coding-system (name) (error "No such coding system"))
(lyskom-provide-function string-width (str) (length str))
......
......@@ -373,14 +373,14 @@ the resulting string may be narrower than END-COLUMN."
(if (< emacs-major-version 20)
(fset 'lyskom-string= (symbol-function 'string=))
(defun lyskom-string= (s1 s2)
(string= (if (multibyte-string-p s1)
(string= (and s1 (if (multibyte-string-p s1)
s1
(decode-coding-string s1 (lyskom-language-coding
lyskom-language)))
(if (multibyte-string-p s2)
lyskom-language))))
(and s2 (if (multibyte-string-p s2)
s2
(decode-coding-string s2 (lyskom-language-coding
lyskom-language))))))))
lyskom-language)))))))))
(defun lyskom-string-assoc (key list)
"Return non-nil if KEY is the same string as the car of an element of LIST.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment