Rename unsafeFreeze to basicUnsafeFreeze and add unsafeFreeze as a free function