parsing expressions with nesting