Fix some orders of operations, and ensure the correct exception is thrown
if assignment is attempted on a non-lvalue.