Use parse_expression()

Use parse_expression() to allow passing object attributes, hopefully fixes #1.