As far as I can tell inventing an invalid key id will just cause errors on future API calls, there is no way to trigger memory unsafety, so this function should not be marked unsafe
. To reduce the chance of users using this incorrectly it could be renamed to new_unchecked
to highlight that it's up to the user to ensure they use a valid id.