From 543704f0f54cbb1de78754ad8a323c482ab6829c Mon Sep 17 00:00:00 2001 From: colin Date: Sat, 14 Dec 2024 12:29:29 -0800 Subject: Loop style nits --- src/canvas-language.lisp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/canvas-language.lisp') diff --git a/src/canvas-language.lisp b/src/canvas-language.lisp index 1a8b12e..5bdf1c8 100644 --- a/src/canvas-language.lisp +++ b/src/canvas-language.lisp @@ -95,7 +95,7 @@ integer." (defun rel-to-current-pos (path) (destructuring-bind (cx cy) *current-pen-position* - (loop for (x y) in path collect (list (+ cx x) (+ cy y))))) + (loop :for (x y) :in path :collect (list (+ cx x) (+ cy y))))) (defun move-pen-to (x y) "Sets the pen's position without drawing. " @@ -152,11 +152,11 @@ the pen relative to its antecedent, look at STROKE-STEPS" (defun steps-to-concrete-points (steps) (loop - with (cx cy) = *current-pen-position* - for (dx dy) in steps - do (incf cx dx) - (incf cy dy) - collect (list cx cy))) + :with (cx cy) := *current-pen-position* + :for (dx dy) :in steps + :do (incf cx dx) + (incf cy dy) + :collect (list cx cy))) (defun stroke-steps (steps) "STEPS is a list of (dx dy) steps. The pen starts at the current -- cgit v1.2.3