Serialize empty numbers as nulls. Fixes #261.