1. ;;;name:BF-str->lst
    2. ;;;desc:字符串转成列表--leemac
    3. ;;;arg:str:字符串
    4. ;;;arg:del:分隔符
    5. ;;;return:字符串列表
    6. ;;;example<img src=\"static/image/smiley/default/sad.gif\" smilieid=\"2\" border=\"0\" alt=\"\" />BF-str->lst "a-b-c" "-")
    7. (defun BF-str->lst(str del / pos)
    8. (if (setq pos (vl-string-search del str))
    9. (cons (substr str 1 pos)
    10. (BF-str->lst (substr str (+ pos 1 (strlen del))) del)
    11. )
    12. (list str)
    13. )
    14. )
    15. (while (vl-string-search "\\" fileline)
    16. (setq fileline (vl-string-subst "" "\\" fileline))
    17. )