Fix update statements containing an empty set

Fixes #304. See the issue for full context.

Let me know if you want me to change anything!