At the moment I have the following code in Emacs Lisp: (defun substitute-expression(input-file output-file reg-exp substitute-str) (let ((match-length)) (switch-to-buffer (find-file-noselect input-file t t)) (buffer-disable-undo) (while (re-search-forward reg-exp nil t) (setq match-length (- (point) (match-beginning 0))) (while (> match-length (length substitute-str)) (setq substitute-str (concat substitute-str substitute-str))) (replace-match (substring substitute-str 0 match-length)) ) (write-region (point-min) (point-max) output-file)))
To get my first taste of writing in Guile (and evaluating if changing to Guile is worthwhile) I was wondering how to do the same in Guile. Also I use: (byte-compile '"'"'substitute-expression) This compiles the function before it is executed, which speeds things considerable up. Is this also possible with Guile? -- Cecil Westerhof Senior Software Engineer LinkedIn: http://www.linkedin.com/in/cecilwesterhof