[comp.lang.pascal] procedures as record members

eric@hplvec.LVLD.HP.COM (Eric Waldheim) (06/26/91)

I'm having a problem with procedures as members of records in
record constants.  My compiler gives me "Identifier is not of the
appropriate class;" when I try to put a procedure in a record constructor.
It likes the record definition just fine though.
A short example follows:

{-------------------------------------------------------}
program Proc_in_Record_Test;

   type
      my_record_type = record
                           proc : procedure( x : integer );
                       end;

   procedure a_proc( x : integer );
   const
      a_record = my_record_type[ proc: a_proc ];
      {Error here : Identifier is not of the appropriate class;}
   begin 
   end;

begin
end.
{---------------------------------------------------------}

I'm running HP-UX 7.0 on a 370.
and the version of my pascal compiler is:
/bin/pc:
        12.3    89/07/14

Any insight would be appreciated.
Eric.