From 82657abf32990a9ee72f28e91759529775307e5a Mon Sep 17 00:00:00 2001 From: Lee Spector Date: Thu, 7 Dec 2023 16:47:50 -0500 Subject: [PATCH] Do not consider adding at a :gap --- src/propeller/variation.cljc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/propeller/variation.cljc b/src/propeller/variation.cljc index d9495fc..3fbd679 100644 --- a/src/propeller/variation.cljc +++ b/src/propeller/variation.cljc @@ -111,7 +111,8 @@ The function `new-individual` returns a new individual produced by selection and existing instruction." [plushy instructions umad-rate] (apply concat - (map #(if (< (rand) umad-rate) + (map #(if (and (not= % :gap) + (< (rand) umad-rate)) (shuffle [% (utils/random-instruction instructions)]) [%]) plushy)))