Handle parsing of patterns.

Still to handle translation/conversion to ASTs.