Better syntax definition

New syntax definition which should correctly handle class methods and argument types in functions.
Fixes #8