Skip to content
  • Leon Arnott's avatar
    Implemented the (event:) macro, an alternative to (live:), along with the "when" lambda clause. · 4a431f886235
    Leon Arnott authored
    (event:), unlike (live:), live-renders the hook only once, and only when the given lambda, which is run every 20ms, produces true. The new lambda clause, "when", is just a version of "where" typed to only be accepted by (event:). Moreover, it can't take any temp variables or refer to "it" - it must refer to globals or local temp variables outside of it. This contradicts the definition of a "lambda", but I needed a way to express deferred computation to make this macro work, and this seems smoothest from the coder's perspective.
    
    Also fixed a bug where debug view would write messages referring to global variables as if they were in a temp variable store.
    4a431f886235