Search Issue Tracker
Fixed
Fixed in 2021.3.14f1, 2022.1.23f1, 2022.2.0b16, 2023.1.0a17
Votes
0
Found in
2020.3.38f1
2021.3.8f1
2022.1.13f1
2022.2.0b5
2023.1.0a6
Issue ID
UUM-11944
Regression
No
[IL2CPP] "Object must be the same type as the enum" on call to Enum.CompareTo
How to reproduce:
1. Open the attached project (“IN-11189_repro.zip“)
2. Build And Run standalone player
Expected result: "Object must be the same type as the enum" exception is not thrown
Actual result: "Object must be the same type as the enum" exception is thrown
Reproducible with: 2020.3.38f1, 2021.3.8f1, 2022.1.13f1, 2022.2.0b5, 2023.1.0a6
Reproducible on:
macOS 12.4 (Intel)
Windows 10
ArgumentException: Object must be the same type as the enum. The type passed in was 'PlayerAnimation'; the enum type was 'PlayerAnimation'.
at System.Enum.CompareTo (System.Object target) [0x00000] in <00000000000000000000000000000000>:0
at System.Collections.Comparer.Compare (System.Object a, System.Object b) [0x00000] in <00000000000000000000000000000000>:0
at System.Collections.Generic.ObjectComparer{{1[T].Compare (T x, T y) [0x00000] in <00000000000000000000000000000000>:0 at System.Collections.Generic.SortedDictionary}}2+KeyValuePairComparer[TKey,TValue].Compare (System.Collections.Generic.KeyValuePair{{2[TKey,TValue] x, System.Collections.Generic.KeyValuePair}}2[TKey,TValue] y) [0x00000] in <00000000000000000000000000000000>:0
at System.Collections.Generic.SortedSet{{1[T].FindNode (T item) [0x00000] in <00000000000000000000000000000000>:0 at System.Collections.Generic.SortedSet}}1[T].Contains (T item) [0x00000] in <00000000000000000000000000000000>:0
at System.Collections.Generic.SortedDictionary`2[TKey,TValue].ContainsKey (TKey key) [0x00000] in <00000000000000000000000000000000>:0
at Test.Start () [0x00000] in <00000000000000000000000000000000>:0
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- "The name 'Unwrapping' does not exist in the current context" is thrown when using Unwrapping.GeneratePerTriangleUV in the Build
- The "Add Component" context menu root level has a parent when is reopened after selecting a Component
- [Android] Crash on memcpy when building for Android Platform
- Cannot create DropdownField with nested choices when using UIToolkit
- Lightmaps are baked incorrectly for GameObjects when their Position is <=-2048 or >=2048 on any of the coordinates
Add comment