comp.lang.ada
 help / color / mirror / Atom feed
From: dewar@merv.cs.nyu.edu (Robert Dewar)
Subject: Re: Enumeration literal visibility and use type
Date: 1998/05/28
Date: 1998-05-28T00:00:00+00:00	[thread overview]
Message-ID: <dewar.896386950@merv> (raw)
In-Reply-To: 356D767E.41C6@ifn.com


Thomas said

<<My usual Ada83 way around this was to import the operator using a
renames clause.
i.e.  function "+"(l,r : my_pkg.my_type) return my_pkg.my_type renames
my_pkg."+";

This allows the infix use of the binary operator.  It is still clumsy
and not very pretty but it sure makes the body of the code read better.
>>


You and x zillion other Ada 83 programmers, this is indeed an absolutely
standard technique among those who do not like to use "use".

And it is EXACTLY this stuff that "use type" was designed to consign to
the rubbish bin!





  reply	other threads:[~1998-05-28  0:00 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <6kej65$dnh$1@hermes.seas.smu.edu| <6kejt5$75u@gcsin3.geccs.gecm.com>
1998-05-26  0:00 ` Enumeration literal visibility and use type William Bralick
1998-05-26  0:00   ` Fergus Henderson
1998-05-27  0:00     ` John McCabe
1998-05-27  0:00       ` Peter Amey
1998-05-27  0:00         ` John McCabe
1998-05-27  0:00       ` Robert Dewar
1998-05-28  0:00         ` John McCabe
1998-05-28  0:00           ` Robert Dewar
1998-05-29  0:00             ` John McCabe
1998-05-28  0:00           ` Thomas Hood
1998-05-28  0:00             ` Robert Dewar [this message]
1998-05-27  0:00     ` William Bralick
1998-05-26  0:00 William Bralick
1998-05-26  0:00 ` John McCabe
1998-05-26  0:00   ` David C. Hoos, Sr.
1998-05-26  0:00     ` Matthew Heaney
1998-05-27  0:00       ` John McCabe
1998-05-26  0:00     ` John English
1998-05-26  0:00     ` Ray Blaak
1998-05-27  0:00       ` John McCabe
1998-05-27  0:00         ` John McCabe
1998-05-27  0:00     ` Robert Dewar
1998-05-27  0:00       ` Matthew Heaney
1998-05-26  0:00 ` Roger Racine
1998-05-26  0:00 ` Matthew Heaney
1998-05-27  0:00   ` John McCabe
1998-05-27  0:00   ` William Bralick
1998-05-27  0:00   ` Mats Weber
replies disabled

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