### Godot version

v4.0.beta17.mono.official [c40020513]

### System information

Window 11, Forward+, GTX 1060

### Issue description

Adding two theme variations in a row result to a  crash.

https://user-images.githubusercontent.com/93253123/217037249-1ce1d56d-beb6-4435-83ad-9f8a07fe0e96.mp4



### Steps to reproduce

1. Create a project.
2. Create a theme.
3. Double click to go in the theme editor.
4. Click on manage items buttons.
5. In the add type field type a name to add a type.
6. type another name to add a second type.
7. Crash.

### Minimal reproduction project

[ThemeVariationCrash.zip](https://github.com/godotengine/godot/files/10665863/ThemeVariationCrash.zip)

GDVIRTUAL1(_set_read_only, bool)
	void _update_pin_flags();
protected:
	void _notification(int p_what);
	static void _bind_methods();
	virtual void _set_read_only(bool p_read_only);
	virtual void gui_input(const Ref<InputEvent> &p_event) override;
	virtual void shortcut_input(const Ref<InputEvent> &p_event) override;
	const Color *_get_property_colors();
	virtual Variant _get_cache_value(const StringName &p_prop, bool &r_valid) const;
	virtual StringName _get_revert_property() const;
public:
	void emit_changed(const StringName &p_property, const Variant &p_value, const StringName &p_field = StringName(), bool p_changing = false);
	virtual Size2 get_minimum_size() const override;
	void set_label(const String &p_label);
	String get_label() const;
	void set_read_only(bool p_read_only);
	bool is_read_only() const;
	Object *get_edited_object();
	StringName get_edited_property() const;
	void set_doc_path(const String &p_doc_path);
	virtual void update_property();
	void update_editor_property_status();
	virtual bool use_keying_next() const;
	void set_checkable(bool p_checkable);
	bool is_checkable() const;
	void set_checked(bool p_checked);
	bool is_checked() const;
	void set_draw_warning(bool p_draw_warning);
	bool is_draw_warning() const;