I have a job that runs fine if I don’t specify a [BurstCompile] attribute. If I do, I get this error:
C:\Users\Marnel\AppData\Local\Unity\cache\packages\staging-packages.unity.com\com.unity.entities@0.0.12-preview.17\Unity.Entities\Types\TypeManager.cs(110,13): error: Loading from a static field System.Int32 Unity.Entities.TypeManager/StaticTypeLookup
1::typeIndex` is not supported by burst
While processing function Unity.Entities.TypeManager, Unity.Entities, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null::GetTypeIndex
1[CommonEcs.Changed, Assembly-CSharp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null]`
While compiling job: System.Void Unity.Jobs.IJobParallelForExtensions/ParallelForJobStruct`1<CommonEcs.IdentifySpriteManagerChangedValuesSystem/Job>::Execute(T&,System.IntPtr,System.IntPtr,Unity.Jobs.LowLevel.Unsafe.JobRanges&,System.Int32)
Compiler exception: System.NotSupportedException: Loading from a static field System.Int32 Unity.Entities.TypeManager/StaticTypeLookup
1::typeIndex` is not supported by burst
at Burst.Compiler.IL.ILVisitor.NotSupported (Burst.Compiler.IL.Syntax.ILInstruction inst) [0x0016b] in :0
at Burst.Compiler.IL.ILVisitor.Ldsfld (Burst.Compiler.IL.Syntax.ILInstruction inst) [0x0006c] in :0
at Burst.Compiler.IL.ILVisitor.CompileInternal (Burst.Compiler.IL.Syntax.ILInstruction inst) [0x004de] in :0
at Burst.Compiler.IL.ILVerifier.CompileInternal (Burst.Compiler.IL.Syntax.ILInstruction inst) [0x00000] in :0
CommoEcs.Changed, which is referenced in the error is just a tag IComponentData. There are more error after this but this is the first one that is shown in the console log.