Search Unity

  1. Unity Asset Manager is now available in public beta. Try it out now and join the conversation here in the forums.
    Dismiss Notice

IL2CPP Enum error

Discussion in '2021.2 Beta' started by PatientZero, Jul 30, 2021.

  1. PatientZero

    PatientZero

    Joined:
    Apr 8, 2015
    Posts:
    31
    Hi,

    trying out the beta with my project leads to a il2cpp error when compiling some of the third party libraries in the project:

    Building Library\Bee\artifacts\Android\d8kz\y6wb_ThirdParty.o failed with output:
    In file included from C:/UnityProjects/EMERGE_Home_Kopie/Library/Bee/artifacts/Android/il2cppOutput/cpp/ThirdParty.cpp:1:
    In file included from C:/Program Files/Unity/Hub/Editor/2021.2.0b4/Editor/Data/il2cpp/libil2cpp/pch\pch-cpp.hpp:6:
    In file included from C:/Program Files\Unity\Hub\Editor\2021.2.0b4\Editor\Data\il2cpp\libil2cpp\codegen\il2cpp-codegen.h:10:
    C:\Program Files\Unity\Hub\Editor\2021.2.0b4\Editor\Data\il2cpp\libil2cpp\codegen\il2cpp-codegen-il2cpp.h(402,23): error: invalid operands to binary expression ('Enum_t2A1A94B24E3B776EEF4E5E485E290BB9D4D072E2 *' and 'Enum_t2A1A94B24E3B776EEF4E5E485E290BB9D4D072E2 *')
    return (enumValue & flag) == flag;
    ~~~~~~~~~ ^ ~~~~
    C:\UnityProjects\EMERGE_Home_Kopie\Library\Bee\artifacts\Android\il2cppOutput\cpp\ThirdParty.cpp(7175,14): note: in instantiation of function template specialization 'il2cpp_codegen_enum_has_flag<Enum_t2A1A94B24E3B776EEF4E5E485E290BB9D4D072E2 *>' requested here
    bool L_4 = il2cpp_codegen_enum_has_flag(((Enum_t2A1A94B24E3B776EEF4E5E485E290BB9D4D072E2*)CastclassClass((RuntimeObject*)L_1, Enum_t2A1A94B24E3B776EEF4E5E485E290BB9D4D072E2_il2cpp_TypeInfo_var)), ((Enum_t2A1A94B24E3B776EEF4E5E485E290BB9D4D072E2*)CastclassClass((RuntimeObject*)L_3, Enum_t2A1A94B24E3B776EEF4E5E485E290BB9D4D072E2_il2cpp_TypeInfo_var)));
    ^
    1 error generated.
    UnityEditor.BuildPipeline:BuildPlayer (UnityEditor.BuildPlayerOptions)
    PatientZeroGames.BuildAutomation.Editor.PrebuildProcess:preProcess (UnityEditor.BuildPlayerOptions) (at Library/PackageCache/com.patientzero-games.buildautomation@a640cd6007/Editor/Scripts/PrebuildProcess.cs:74)
    UnityEngine.GUIUtility:processEvent (int,intptr,bool&)
     
  2. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,929
  3. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,929
    LeonhardP and KamilCSPS like this.
  4. PatientZero

    PatientZero

    Joined:
    Apr 8, 2015
    Posts:
    31