- Home /
Unity4.6.6Compile errors
player setting is IL2CPP,ARM64,.NET2.0,fast but no exception.
when I Compile the xcode project,I got many erros like this:
~/xcodeprj/Classes/Native/Bulk_Generics_13.cpp:17377:10: Cannot initialize return object of type 'SingletonTaskMono_1_t15549 ' with an rvalue of type 'SingletonTaskMono_1_t15548 '
extern "C" SingletonTaskMono_1_t15549 * SingletonTaskMono_1_get_mInstance_m118625_gshared (Object_t * __this /* static, unused */, const MethodInfo* method)
{
SingletonTaskMono_1_t15548 * L_14 = L_13;
return ((SingletonTaskMono_1_t15548 *)L_14);
}
ERROE:
/Users/raid/ComPrj/siege466test/xcodeprj/Classes/Native/Bulk_Generics_13.cpp:17377:10: Cannot initialize return object of type 'SingletonTaskMono_1_t15549 *' with an rvalue of type 'SingletonTaskMono_1_t15548 *'
struct SingletonTaskMono_1_t15549 : public TaskMonoBehaviour_t1219
{
};
struct SingletonTaskMono_1_t15549_StaticFields{
// T siege2d.SingletonTaskMono`1<siege2d.SingletonTaskMono`1<System.Object>>::_mInstance
SingletonTaskMono_1_t15548 * ____mInstance_2;
// System.Boolean siege2d.SingletonTaskMono`1<siege2d.SingletonTaskMono`1<System.Object>>::isApplicationQuit
bool ___isApplicationQuit_3;
};
struct SingletonTaskMono_1_t15548 : public TaskMonoBehaviour_t1219
{
};
struct SingletonTaskMono_1_t15548_StaticFields{
// T siege2d.SingletonTaskMono`1<System.Object>::_mInstance
Object_t * ____mInstance_2;
// System.Boolean siege2d.SingletonTaskMono`1<System.Object>::isApplicationQuit
bool ___isApplicationQuit_3;
};
xcode project generate by unity 4.6.6 f2.
xcode version is 6.3
I have tried, but still there,not fix. Even I try to change code to :
public class Singleton : $$anonymous$$onoBehaviour where T : Singleton {
protected static Singleton<T> mInstance {
get {
return (Singleton<T>)_mInstance;
}
}
private static T _mInstance;
}
the cpp code made by il2cpp still as the same as above.
oh, you mean mono not use il2cpp,i tried, this is ok。 but we need build for ios 64.
Please try the latest patch release version, 4.6.6p4 (http://unity3d.com/unity/qa/patch-releases). If the problem still occurs, please submit a bug report, we would like to correct it.
O$$anonymous$$,I have tried 4.6.6p4. but get new error: Classes/Native/Bulk_Generics_2.cpp:18404:3: No matching function for call to 'il2cpp_codegen_raise_exception'
code:
Object_t * L_56 = V_5;
Object_t * L_57 = L_56;
il2cpp_codegen_raise_exception(((Object_t *)L_57));
could I just convert Object_t* to Il2CppCodeGenException *?
O$$anonymous$$, I just switch Object_t* to Il2CppCodeGenException *
Answer by raid_2015 · Jun 30, 2015 at 11:08 AM
it seems when the c#code like this:
public class Singleton<T> : MonoBehaviour where T : Singleton<T> {
protected static Singleton<T> mInstance {
get {
return _mInstance;
}
}
private static T _mInstance;
}
will make this error.
SingletonTaskMono_1_t15549 is Singleton< T >
SingletonTaskMono_1_t15548 is T
Answer by huminado · Aug 30, 2015 at 10:58 PM
@JoshPeterson I get the same errors for Unity3D 4.6.6f2
I've attached a zip file of files from the project's Temp directory and the errors as they appeared in Xcode. This happened when I tried adding AntiLunchBox Musthave iOS Combo Pack to a project using uFrame MVVM - note I didn't even change the scene or code or anything - all I did was import Musthave. Also I'm not using U3DXT.
Please submit a bug report for this issue in the Unity Editor. That way we can properly route it through our QA channels and feedback to you when it is corrected. Once, the bug is submitted, please respond here with the bug number. Thanks!
reported using Unity 4.6.8 which resulted in different errors but also went away when IL2CPP was turned off.
Thanks. Good luck too! It would really be nice to build with IL2CPP turned on again.
@hu$$anonymous$$ado Can you let me know the bug report number? Thanks.
724135
https://fogbugz.unity3d.com/default.asp?724135_0bucuvlkqheuut16
I'm assu$$anonymous$$g this is still going to be a problem in 5.x too.
@hu$$anonymous$$ado: Thanks, I've ping our QA $$anonymous$$m to take a look at this.
Your answer
![](https://koobas.hobune.stream/wayback/20220613201540im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
"Culture name neutral is not supported" when using Parse.Unity.dll 2 Answers
How to get readable stacktrace in IOS build? 1 Answer
Can't run the game on iOS8 using Unity4.6.9 and xCode7 1 Answer
Linker error - Unity on iOS/React Native project 1 Answer
Missing headers in XCode project generated by Unity 1 Answer