From 301704e959814e2c85bccceb99842d88ee15e5a3 Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Sun, 15 Sep 2019 14:59:29 -0400 Subject: Disabled loop optimization in the old compiler. --- luxc/src/lux/optimizer.clj | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) (limited to 'luxc') diff --git a/luxc/src/lux/optimizer.clj b/luxc/src/lux/optimizer.clj index e1187594c..0c1b304e0 100644 --- a/luxc/src/lux/optimizer.clj +++ b/luxc/src/lux/optimizer.clj @@ -1028,16 +1028,18 @@ (&a/$apply func args) (|let [=func (pass-0 top-level-func? func) =args (&/|map (partial pass-0 top-level-func?) args)] - (|case =func - [_ ($ann [_ ($function _register-offset _arity _scope _captured _body)] - _)] - (if (and (= _arity (&/|length =args)) - (not (contains-self-reference? _body))) - (inline-loop meta _register-offset _scope _captured =args _body) - (&/T [meta ($apply =func =args)])) + (&/T [meta ($apply =func =args)]) + ;; (|case =func + ;; [_ ($ann [_ ($function _register-offset _arity _scope _captured _body)] + ;; _)] + ;; (if (and (= _arity (&/|length =args)) + ;; (not (contains-self-reference? _body))) + ;; (inline-loop meta _register-offset _scope _captured =args _body) + ;; (&/T [meta ($apply =func =args)])) - _ - (&/T [meta ($apply =func =args)]))) + ;; _ + ;; (&/T [meta ($apply =func =args)])) + ) (&a/$case value branches) (let [normal-case-optim (fn [] -- cgit v1.2.3