add object-like syntax for simple functions