Fix some NPEs in unit/value stringification