comp.lang.ada
 help / color / mirror / Atom feed
* Generic operation and prefixed notation
@ 2010-06-14 17:47 Marek Janukowicz
  2010-06-14 18:09 ` Dmitry A. Kazakov
  2010-06-14 18:11 ` Yannick Duchêne (Hibou57)
  0 siblings, 2 replies; 4+ messages in thread
From: Marek Janukowicz @ 2010-06-14 17:47 UTC (permalink / raw)


Hello

I'm still working on a problem I asked about last week (thanks for all the 
answers). Another question that arose recently: is there any way of calling 
an instantiation of generic operation with prefixed notation?

Given a simplified example:

  type Model is tagged record
    null
  end record;

  generic
    Attr_Name : String;
  procedure Get_Attribute( M : Model );

  procedure Get_Name is new Get_Attribute( "Name" );

Now I can call it with:
  Get_Name( M );

but I'd rather use
  M.Get_Name;

which complains about Get_Name not being present.

Is there any other way to achieve it?

-- 
Marek Janukowicz

--- news://freenews.netfront.net/ - complaints: news@netfront.net ---



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2010-06-15  1:14 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-06-14 17:47 Generic operation and prefixed notation Marek Janukowicz
2010-06-14 18:09 ` Dmitry A. Kazakov
2010-06-14 18:11 ` Yannick Duchêne (Hibou57)
2010-06-15  1:14   ` Adam Beneschan

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