### Godot version

4.1.beta1

### System information

macOS 13.3.1 mobile renderer

### Issue description

Trying to open and edit one of my visual shaders now consistently crashes Godot 4.1beta1. 

The shader was made and edited fine in earlier versions of Godot 4 and I'm not certain what is special with this shader (attached below for investigation). Opening and editing other visual shaders works fine for me. The only thing I can think of that this shader uses that other do not is the gradient node, though as I can't open it I'm not sure what else might be going on in it.

### Steps to reproduce

Open the attached visual shader (in any project)

### Minimal reproduction project

[ConnectBlendShader.tres.zip](https://www.lostminds.com/godot/ConnectBlendShader.tres.zip)
const Ref<InputEventMouseButton> mb = p_event;
	if (mb.is_valid()) {
		if (mb->get_button_index() == MouseButton::LEFT) {
			if (mb->is_pressed()) {
				grabbed = get_handle_at(mb->get_position() - offset);
				if (grabbed != HANDLE_NONE) {
					initial_grab_pos = _get_handle_pos(grabbed) / size;
					queue_redraw();
				}
			} else {
				
				if (grabbed != HANDLE_NONE) {
					set_fill_pos(_get_handle_pos(grabbed) / size);
					grabbed = HANDLE_NONE;
					queue_redraw();
				}
			}
		}
		if (grabbed != HANDLE_NONE && mb->is_pressed() && mb->get_button_index() == MouseButton::RIGHT) {
			texture->set((grabbed == HANDLE_FROM) ? SNAME("fill_from") : SNAME("fill_to"), initial_grab_pos);
			grabbed = HANDLE_NONE;
			queue_redraw();
		}
	}