Marks a field instance and its data for deletion.
\Drupal\field\Plugin\Core\Entity\FieldInstance $instance: The field instance.
$field_cleanup: If TRUE, the field will be deleted as well if its last instance is being deleted. If FALSE, it is the caller's responsibility to handle the case of fields left without instances. Defaults to TRUE.
as of Drupal 8.0. Use $instance->delete().
function field_delete_instance(FieldInstance $instance, $field_cleanup = TRUE) {
$instance
->delete($field_cleanup);
}