gilch / hebigo

蛇語(HEH-bee-go): An indentation-based skin for Hissp.
https://github.com/gilch/hissp
Mozilla Public License 2.0
24 stars 3 forks source link

Implement !of: macro #34

Closed gilch closed 5 years ago

gilch commented 5 years ago

Gets attrs or items from an object. Can chain multiple keys/identifiers. The prefix ordering is the opposite of what Python uses, but it's more consistent with function applications. Unary functions (including "nullary" methods with the .foo: self syntax) compose very naturally with !of: this way. See tests for examples.