Search Issue Tracker
By Design
By Design in 1.8.X
Votes
0
Found in [Package]
1.8.23
Issue ID
BUR-2870
Regression
No
Burst throws a BC1051 error when the project contains a DefaultInterpolatedStringHandler
Slack discussion: here
Reproduction steps:
1. Open the attached “IN-107514_BurstInterpolationHandlerBug.zip“ project
2. Wait for the Burst compilation to finish
3. Observe the Console
Expected result: No errors are present
Actual result: “Burst error BC1051 …” error appears:
{code:java}
/opt/UnitySrc/bugs/IN-107514_BurstInterpolationHandlerBug/Assets/Runtime/DebugLogJob.cs(14,9): Burst error BC1051: Invalid managed type found for the field `_provider` of the struct `System.Runtime.CompilerServices.DefaultInterpolatedStringHandler`.: the type `System.IFormatProvider` is a managed type and is not supported at DebugLogJob.Execute(DebugLogJob* this) (at /opt/UnitySrc/bugs/IN-107514_BurstInterpolationHandlerBug/Assets/Runtime/DebugLogJob.cs:14)
at Unity.Jobs.IJobExtensions.JobStruct`1<DebugLogJob>.Execute(ref DebugLogJob data, System.IntPtr additionalPtr, System.IntPtr bufferRangePatchData, ref Unity.Jobs.LowLevel.Unsafe.JobRanges ranges, int jobIndex) (at /Users/bokken/build/output/unity/unity/Runtime/Jobs/Managed/IJob.cs:61)
While compiling job:
Unity.Jobs.IJobExtensions+JobStruct`1[[DebugLogJob, Assembly-CSharp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null]], UnityEngine.CoreModule, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null::Execute(DebugLogJob&, Assembly-CSharp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null|System.IntPtr, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089|System.IntPtr, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089|Unity.Jobs.LowLevel.Unsafe.JobRanges&, UnityEngine.CoreModule, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null|System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089)
{code}
Reproducible with: 1.7.4 (2022.3.64f1, 6000.2.0b9), 1.8.23 (2022.3.64f1, 6000.0.53f1, 6000.1.11f1, 6000.2.0b9, 6000.3.0a1)
Reproducible on: M1 Max MacOS 15.5 (Tested by CQA), Windows 11 (User’s platform)
Not reproducible on: No other environment tested
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
- Uninitialized variable warning appears in the Inspector of a custom shader when the variable is initialized
- "Failed creating toolbar element from ID..." error is thrown when resetting the Scene view Overlay layout while an Asset Transformer Toolbox overlay is active
- Entity ID for Font Assets is serialized twice which throws an error when using Debug Inspector
- Play Mode can be entered when disabling Adaptive Performance and pressing either the Play Mode button or the keyboard shortcut to enter Play Mode before recompilation leading to errors and warnings thrown
- Parent ListView element also becomes selected when inner ListView element is selected
Resolution Note:
The error appears due to DefaultInterpolatedStringHandler.cs being added as a source to the project. DefaultInterpolatedStringHandler.cs is part of a more modern Base Class Library (BCL) than the Unity Engine/Burst currently supports. This bug is therefore closed as a "As Designed" for now.
Resolution Note (1.8.X):
The error appears due to DefaultInterpolatedStringHandler.cs being added as a source to the project. DefaultInterpolatedStringHandler.cs is part of a more modern Base Class Library (BCL) than the Unity Engine/Burst currently supports. This bug is therefore closed as a "As Designed" for now.