Reproduction steps:
1. Open the attached “BugRepro” project
2. Open the “Assets/Scenes/SampleScene.unity” Scene
3. Select “BrokenInspector” GameObject in the Hierarchy window
4. Observe the Console window
Expected result: No errors are thrown
Actual result: “System.NullReferenceException: Object reference not set to an instance of an object” error is thrown
Reproducible with: 2023.3.0a2, 6000.0.7f1
Not reproducible with: 2021.3.39f1, 2022.3.33f1, 2023.2.0a23
Reproducible on: Windows 11
Not reproducible on: No other environment tested