Anonymous functions and implicit function specialization internal compiler error
The following program gives internal compiler error 2002071001.
Free Pascal Compiler version 3.3.1 [2022/05/27] for aarch64
{$mode objfpc}
{$modeswitch anonymousfunctions}
{$modeswitch implicitfunctionspecialization}
program internal_error_2002071001;
type
TFunc = function(value: integer): Boolean;
generic procedure Perform<TFunc>(func: TFunc);
begin
end;
begin
Perform(function (value: Integer): Boolean
begin
result := value > 100;
end);
end.