Fix toJSLOND conversion of Type objects

This could cause circular references when calling JSON.stringify on the
exported object.