- (loop with skip = (if (memq 'intangible-sides flags)
- 1
- 4)
- for line in lines
- do (loop
- ;; this is slow and stupid
- ;; todo: use ‘compare-strings’
- for x below w
- do (let* ((i (* x cpp))
- (el (substring line i (+ i cpp))))
- (if (string= px el)
- (forward-char cpp)
- (insert el)
- (delete-char cpp))))
- do (when (< (point) (point-max))
- (forward-char skip)))
+ (cl-loop with skip = (if (memq 'intangible-sides flags)
+ 1
+ 4)
+ for line in lines
+ do (cl-loop
+ ;; this is slow and stupid
+ ;; todo: use ‘compare-strings’
+ for x below w
+ do (let* ((i (* x cpp))
+ (el (substring line i (+ i cpp))))
+ (if (string= px el)
+ (forward-char cpp)
+ (insert el)
+ (delete-char cpp))))
+ do (when (< (point) (point-max))
+ (forward-char skip)))