Commit 65dec441 authored by Per Cederqvist's avatar Per Cederqvist

Fix user-area parsing.

* flags.el (lyskom-get-holerith): Only strip *initial*
whitespace. (When given the string "3Hfoo 7Hx\n asdf" as input, it
would treat "3Hfoo 7Hx\n " as initial whitespace, and fail when it
attempted to parse "asdf" as a Hollerith string.)
parent c6851654
2012-10-01 Per Cederqvist <cederp@opera.com>
Fix user-area parsing.
* flags.el (lyskom-get-holerith): Only strip *initial*
whitespace. (When given the string "3Hfoo 7Hx\n asdf" as input, it
would treat "3Hfoo 7Hx\n " as initial whitespace, and fail when it
attempted to parse "asdf" as a Hollerith string.)
2011-01-06 David Byers <davby@ida.liu.se>
Compatibility with Emacs 24:
......
......@@ -435,12 +435,12 @@ If optional NO-CODING is set, assume the string has internal coding."
;; Strip initial whitespace
(when (string-match "^\\(\\s-\\|[\n\r]\\)+" string)
(when (string-match "\\`\\(\\s-\\|[\n\r]\\)+" string)
(setq string (substring string (match-end 0))))
;; Read the explicit coding, if any
(when (string-match "^[0-9]+C" string)
(when (string-match "\\`[0-9]+C" string)
(let ((len (lyskom-string-to-number string)))
(setq coding (intern
(substring string
......
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