comp.lang.ada
 help / color / mirror / Atom feed
* hiding predefined "="
@ 1986-09-24  7:33 Doug Bryan
  0 siblings, 0 replies; only message in thread
From: Doug Bryan @ 1986-09-24  7:33 UTC (permalink / raw)



To:     "Pat Rogers, High Tech Lab" <ROGERS%uhcl.csnet@CSNET-RELAY.ARPA>

Pat, you were so close.  You had the right idea when you derived from
Integer.  Does the following do what you want?

    package P is
      type LP is limited private;
      function "="( Left, Right : LP ) return Boolean;
    private
      type D  is access Integer;
      type LP is new D;
    end P;

    function "="( Left, Right : LP ) return Boolean is
    begin
      return D (Left) = D (Right);  
    end "=";

doug
-------

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~1986-09-24  7:33 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1986-09-24  7:33 hiding predefined "=" Doug Bryan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox