Re: limited types (Was: Records that could be arrays)



On 28 Feb 2006 09:24:35 -0800, Matthew Heaney wrote:

Dmitry A. Kazakov wrote:

Instantiate Generic_Algorithm with some T and CT. Then put a constraint on
T, that will be a subtype S or a derived type. Now how to get CS from CT?

Easy: instantiate Generic_Algorithm again, on type S.

I still don't see CS.

BTW, if I had CS, would need not to instantiate Generic_Algorithm once
more.

--
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de
.



Relevant Pages

  • Re: Question on LSP
    ... What does it mean for one type to be a subtype of another? ... This *is* a difference between Liskov and DbC, ... there are no objects of the derived type. ... cannot instantiate subtype without breaking type ...
    (comp.object)
  • Re: limited types (Was: Records that could be arrays)
    ... Instantiate Generic_Algorithm with some T and CT. ... Then put a constraint on ... that will be a subtype S or a derived type. ...
    (comp.lang.ada)
  • I now realize WHY my consistency check was pointless: CLP.
    ... I'm still very much a newbie at Prolog, but one of my first experiments was ... to my database for finding obvious math contradictions. ... a constraint differs in how it's used from general ... variables which are tested whenever any code tries to instantiate them. ...
    (comp.lang.prolog)
  • Re: do while loop help ( newbie)
    ... package Ada.Text_IO.Integer_IO for that subtype. ... subtype Four_Digits_Max is Natural range 0..9999; ... instantiate anything. ...
    (comp.lang.ada)