Search Issue Tracker
Fixed in 2021.3.9f1
Fixed in 2021.3.X, 2022.1.X, 2023.1.X, 2023.1.0a5
Votes
0
Found in
2021.3.8f1
2022.1.11f1
2022.2.0b7
2023.1.0a4
Issue ID
UUM-14015
Regression
Yes
Function with a return type of void*[] causes a C++ compiler error on IL2CPP
Reproduction steps:
- Create a new project
- Import the “NewBehaviourScript.cs” script
- Attach the “NewBehaviourScript.cs” to any GameObject in a scene
- Press File → Build And Run
Expected result: Build is successful
Actual result: Build is not successful, errors in the Console
Reproducible with: 2021.2.0a17, 2021.3.8f1, 2022.1.0a1, 2022.1.11f1, 2022.2.0a1, 2022.2.0b7, 2023.1.0a4
Not reproducible with: 2020.3.39f1, 2021.2.0a16, 2021.3.9f1, 2022.1.12f1, 2022.1.15f1, 2023.1.0a5, 2023.1.0a9
Reproduced on: Windows 10
Note: project won’t build if affected by this bug
Part of error:
Building Library\Bee\artifacts\WinPlayerBuildProgram\u1oik\i9ie_bly-CSharp.obj failed with output:
Assembly-CSharp.cpp
C:\Users\oleh.halytskyi\UnityProjects\cppThing\Library\Bee\artifacts\WinPlayerBuildProgram\il2cppOutput\cpp\Assembly-CSharp.cpp(443): error C2440: '=': cannot convert from 'void' to 'VoidU2AU5BU5D_tDABEC795D8DD5AF263B91D9FE3AC7C4BCA43E6D1 '
C:\Users\oleh.halytskyi\UnityProjects\cppThing\Library\Bee\artifacts\WinPlayerBuildProgram\il2cppOutput\cpp\Assembly-CSharp.cpp(443): note: Expressions of type void cannot be converted to other types
C:\Users\oleh.halytskyi\UnityProjects\cppThing\Library\Bee\artifacts\WinPlayerBuildProgram\il2cppOutput\cpp\Assembly-CSharp.cpp(608): error C2562: 'void_ptrArray2_ToArray_mE715C8AA2265AA1865F180299561234D5A8D80D9': 'void' function returning a value
C:\Users\oleh.halytskyi\UnityProjects\cppThing\Library\Bee\artifacts\WinPlayerBuildProgram\il2cppOutput\cpp\Assembly-CSharp.cpp(557): note: see declaration of 'void_ptrArray2_ToArray_mE715C8AA2265AA1865F180299561234D5A8D80D9'
C:\Users\oleh.halytskyi\UnityProjects\cppThing\Library\Bee\artifacts\WinPlayerBuildProgram\il2cppOutput\cpp\Assembly-CSharp.cpp(703): error C2440: '=': cannot convert from 'void' to 'VoidU2AU5BU5D_tDABEC795D8DD5AF263B91D9FE3AC7C4BCA43E6D1 '
C:\Users\oleh.halytskyi\UnityProjects\cppThing\Library\Bee\artifacts\WinPlayerBuildProgram\il2cppOutput\cpp\Assembly-CSharp.cpp(703): note: Expressions of type void cannot be converted to other types
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Out-of-bounds memory access with multiple CanvasRenderers under a Canvas when using Mesh API
- Inspector tries to access file after it was deleted when the file was locked in Inspector window
- Changing Transform values in Search window Inspector loses focus while dragging and stopping mouse without releasing dragging action
- Saving changes on the dirty VFX Graph during the Play mode throws "The referenced script (Unknown) on this Behaviour is missing!" warnings
- VFX Graph Debug Info overlaps the "Initialize" block debug info by default
Resolution Note (fix version 2023.1):
Fixed in 2023.1.0a5
Resolution Note (fix version 2022.1):
Fixed in 2022.1.12f1
Resolution Note (fix version 2021.3):
Fixed in 2021.3.9f1