这个碰到个BUG,
- (defun StrParse (Str Delimiter / SearchStr StringLen return n char)
- (setq SearchStr Str)
- (setq StringLen (strlen SearchStr))
- (setq return '())
- (while (> StringLen 0)
- (setq n 1)
- (setq char (substr SearchStr 1 1))
- (while (and (/= char Delimiter) (/= char ""))
- (setq n (1+ n))
- (setq char (substr SearchStr n 1))
- )
- (setq return (cons (substr SearchStr 1 (1- n)) return))
- (setq SearchStr (substr SearchStr (1+ n) StringLen))
- (setq StringLen (strlen SearchStr))
- )
- (reverse return)
- )
这个函数如果碰到中文目录,就无法正常去除,因为每次取一个字节,二中文占有2个字节, |