rtulip / haystack

Haystack is a compiled, statically typed, stack-based language with opt-in variable assignment.
MIT License
25 stars 2 forks source link

Block expr #190

Closed rtulip closed 1 year ago

rtulip commented 1 year ago

Make blocks an actual expression. This changes a few things:

  1. Functions now just have a single expression as their body, which means that single expression functions no longer need braces
  2. As expressions no longer have an optional block, since it more sense for their scope to be defined by the block they are in

Additionally, there was a small bug fix where access expressions didn't respect aliasing properly.