Beef
Beef copied to clipboard
[BeefBuild][Crash] Failure during codegen for if-statement (callback?.Invoke() case .Err)
Hi there,
After starting debugging or when trying to compile workspace with BeefBuild.exe, it will crash because of the callback null-check inside if-statement with result check. This happens only when case is used. For example if (callback?.Invoke() == .Err) works perfectly fine.
attachment: callback-crash-dump.zip
namespace TestProject
{
using System;
public static class Program
{
public delegate Result<void> Delegate();
public static Delegate callback;
static void Main ()
{
if (callback?.Invoke() case .Err) {}
}
}
}