From: val@fcom.cc.utah.edu (Val Kartchner)
Subject: How do I avoid 'use' in this case?
Date: Thu, 11 Mar 93 16:39:04 GMT
Date: 1993-03-11T16:39:04+00:00 [thread overview]
Message-ID: <1993Mar11.163904.18135@fcom.cc.utah.edu> (raw)
I know that the usage of 'use' is discouraged. I generally agree, but I do
not see a way around it in this case. Is there something that I'm missing?
We have a package called 'FIELD_DEF' which (among other things) defines a
variant record type and an access type for referencing it. Here is the
text of the errors generated for one of the lines:
-- Begin included text
2693 if (comm_addr_group(i,j) /= NULL) then
..........................................1
%ADAC-E-NOTDECLOPOPND, (1) /= is not declared for the given operands [LRM 4.5]
%ADAC-I-SUPPLOPARGTYPE, (1) Result type of the first (or only) operand of /= is
access type field_type_ptr in field_def at line 180
%ADAC-I-POSSUSECALL1, (1) Possibly a selected component of (or use clause for)
package field_def in field_def at line 167 is intended; this would make
implicit binary operator /= (field_type_ptr; field_type_ptr) returning
BOOLEAN declared in field_def at line 180 visible for a legal call
-- End included text
I followed the implied suggestion of the (VAX/VMS) Ada compiler and inserted
a "use FIELD_DEF;" statement. I know that with non-operator functions (i.e.:
functions who's names are alphanumeric + '_'), you can use the package name
to avoid 'use'. As far as I know, there is no equivalent for operators.
Is this true? If not, then how do I do it?
Thanks in advance,
-=:[ VAL ]:=-
--
|================== #include <disclaimer.h> ==================///=============|
| "AMIGA: The computer for the creative mind" (tm) Commodore /// Weber State |
| "Macintosh: The computer for the rest of us"(tm) Apple \\\/// University |
|== "I think, therefore I AMiga" -- val@csulx.weber.edu ==\///= Ogden UT USA =|
next reply other threads:[~1993-03-11 16:39 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
1993-03-11 16:39 Val Kartchner [this message]
1993-03-11 18:17 ` How do I avoid 'use' in this case? MILLS,JOHN M.
1993-03-11 18:20 ` Erik Svensson FOA2
1993-03-16 13:12 ` Sandy Wise
1993-03-18 3:02 ` Adam Beneschan
1993-03-11 18:47 ` Arthur Evans
1993-03-12 17:26 ` Gary Morris @ignite
-- strict thread matches above, loose matches on Subject: below --
1993-03-18 15:58 howland.reston.ans.net!zaphod.mps.ohio-state.edu!uwm.edu!caen!nic.umass.e
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox