A simple Pratt's parser implementation.