Arc Forumnew | comments | leaders | submitlogin
1 point by Pauan 4710 days ago | link | parent

I've actually changed my mind so that I don't mind using parens, but only for function calls. Calls to a vau (def, if, and, let, etc.) shouldn't be wrapped in parens:

   mac accessor -> n v
     uniqs %a
       {def n -> %a
         {{%a v} %a}}

   def or: casevau env
     x    -> (eval x)
     x @r -> let x (eval x)
               if x x (eval {or @r})
The above is a hypothetical mockup for new syntax for Nulan. It's radically different than the current syntax, but I think it looks very clean. At least, compared to the current syntax:

  $mac accessor; N V ->
    $uniqs %A
      [$def N; %A ->
        [[%A V] %A]]

  $defvau $or Env
    X    -> eval X
    X @R -> $let X: eval X
              $if X X: eval [$or @R]