Steps to reproduce:
1. Create new Unity project
2. Open Project Settings window
3. Find and select “Tags and Layers”
4. In “Tags and Layers” expand “Tags”
5. Add a new tag with name “New tag” pressing “+”
6. Add 2nd tag named “New tag (1)”
7. Select and remove “New tag (1)” by pressing “-”
8. Press “-” again
9. Observe the Console window
Actual results: Errors are thrown in the Console window
Expected results: No errors are thrown in the Console window
Reproducible with versions: 6000.0.60f1, 6000.2.8f1, 6000.3.0b7, 6000.4.0a3
Tested on (OS): Windows 11
errors:
- Retrieving array element that was out of bounds
UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)
- NullReferenceException: Object reference not set to an instance of an object
UnityEditor.TagManagerInspector+<>c_DisplayClass16_0.<SetupTags>b_5 (UnityEngine.UIElements.BaseListView listView) (at <3852b49eca73473da3e3282226b08bd7>:0)
UnityEngine.UIElements.BaseListView.OnRemoveClicked () (at <2a9812a7bcc64119a2d9d52e521ff94d>:0)
UnityEngine.UIElements.Clickable.Invoke (UnityEngine.UIElements.EventBase evt) (at <2a9812a7bcc64119a2d9d52e521ff94d>:0)
UnityEngine.UIElements.Clickable.ProcessUpEvent (UnityEngine.UIElements.EventBase evt, UnityEngine.Vector2 localPosition, System.Int32 pointerId) (at <2a9812a7bcc64119a2d9d52e521ff94d>:0)
UnityEngine.UIElements.Clickable.OnPointerUp (UnityEngine.UIElements.PointerUpEvent evt) (at <2a9812a7bcc64119a2d9d52e521ff94d>:0)