Simplify some parsing code
Enhance demo: add proper exception-handling