{ Assertion in Proc() will FAIL if you compile this with fpc 1.0.10.
  It means that "method" was not passed properly to Proc().

  If you change the code
    procedure TObj.CallProcWithMyMethod; begin Proc(MyMethod) end;
  into
    procedure TObj.CallProcWithMyMethod; begin Proc(Self.MyMethod) end;
  (i.e. you explicitly give the "Self" qualifier)
  everything will be fine (Assertion will pass).
}

{$mode DELPHI}
{$assertions+}

uses SysUtils;

type
  TProcOfObj=procedure of object;

procedure Proc(method:TProcOfObj);
var m2:TMethod absolute method;
begin
 Assert(m2.Code <> nil);
end;

type
  TObj=class
    procedure MyMethod;
    procedure CallProcWithMyMethod;
  end;

procedure TObj.MyMethod; begin end;
procedure TObj.CallProcWithMyMethod; begin Proc(MyMethod) end;

var o:TObj;
begin
 o:=TObj.Create;
 try
  o.CallProcWithMyMethod;
 finally o.Free end;
end.
