From 616b33fe205929168130bffc48b51f07bb46d3bd Mon Sep 17 00:00:00 2001 From: Rowan Torbitzky-Lane Date: Fri, 14 Mar 2025 00:54:13 -0500 Subject: [PATCH] buy/hold keyword exec stack handling --- src/propeller/push/interpreter.cljc | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/propeller/push/interpreter.cljc b/src/propeller/push/interpreter.cljc index f811ebc..0df3ed6 100755 --- a/src/propeller/push/interpreter.cljc +++ b/src/propeller/push/interpreter.cljc @@ -11,6 +11,11 @@ instruction (first (:exec state)) literal-type (instructions/get-literal-type instruction)] ; nil for non-literals (cond + ;; + ;; Catch the trading signal keywords before the other + ;; keyword checks. + (some #(= instruction %) '(:buy :sell :hold)) + (state/push-to-stack popped-state :signal instruction) ;; ;; Recognize functional instruction or input instruction (keyword? instruction)