pixie-lang / dust

Magic fairy dust for pixie, i.e. tooling around the language.
GNU Lesser General Public License v3.0
93 stars 14 forks source link

Recur not throwing exception #26

Closed biellls closed 8 years ago

biellls commented 8 years ago

The following code should throw an exception because recur is not called from a tail position. Instead it always returns 1.

(defn factorial [n]
  (if (zero? n)
    1
    (* n (recur (dec n)))))
heyLu commented 8 years ago

This also seems to happen in pixie-vm, so it's not specific to dust. Can you open an issue on pixie itself?

biellls commented 8 years ago

Sorry, my mistake. I meant to post it there.

heyLu commented 8 years ago

No worries. For anyone following along, the issue is pixie-lang/pixie#440.