from Hacker News

Bio – Experimental Lisp dialect, written in Zig

by montyanderson on 7/13/24, 10:11 PM with 34 comments

  • by 1hackaday on 7/14/24, 3:23 PM

    Very interesting. Would be useful to know how this compares to other Lisps and what could be some use cases.
  • by hayley-patton on 7/15/24, 2:01 AM

    What's the experiment?
  • by tmtvl on 7/14/24, 2:29 PM

    Putting closing parentheses on their own lines is extremely cursed.

    I used to like Lisp-1s when I used Scheme, but having used Common Lisp for a while I've come to appreciate Lisp-2s, if only for silly things like...

      (defun foo (list)
        (declare (type List list))
        (assert (> (length list) 1))
        (list (second list)
              (first list)))
    
    Everything else aside it seems like a nice finger exercise for learning Zig.
  • by revskill on 7/14/24, 4:59 PM

    Need a dialect without using bracket.
  • by gleenn on 7/14/24, 4:07 PM

    I see they use they use the actual lambda character "λ" to create functions which is both cool and also probably makes grepping for functions a PITA. It does look pretty but I would have to search the web or write down the random keystroke to generate that symbol.

    An example usage:

    (filter (quicksort '(5 40 1 -3 2) <) (λ (x) (>= x 0)))