hamlet: Parse $of as binding

Among other things, this enables use of pattern matching with record
syntax in $of constructs