Fix operator precedence around writes