From 85d4fd33b00c9058b46047a4b41118bdb82258be Mon Sep 17 00:00:00 2001 From: Rowan Torbitzky-Lane Date: Wed, 22 Jan 2025 00:31:42 -0600 Subject: [PATCH] empty Block for last block instruction --- src/Instructions/CodeInstructions.hs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Instructions/CodeInstructions.hs b/src/Instructions/CodeInstructions.hs index 6a5721a..b29381c 100644 --- a/src/Instructions/CodeInstructions.hs +++ b/src/Instructions/CodeInstructions.hs @@ -20,6 +20,7 @@ extractFirstFromBlock (Block (x : _)) = x extractFirstFromBlock gene = gene extractLastFromBlock :: Gene -> Gene +extractLastFromBlock (Block []) = Block [] extractLastFromBlock (Block xs) = last xs extractLastFromBlock gene = gene