comp.lang.ada
 help / color / mirror / Atom feed
* GNAT NT & Ada.Direct_IO
@ 1995-01-09  4:33 Mark Riordan
  1995-01-09  6:07 ` Robert Dewar
                   ` (2 more replies)
  0 siblings, 3 replies; 9+ messages in thread
From: Mark Riordan @ 1995-01-09  4:33 UTC (permalink / raw)


I have been using GNAT NT 2.0c to try to recompile the
file a-direio.adb, which is the package body Ada.Direct_IO.
When I run:

   gcc -c a-direio.adb

I am surprised to get the message:

"No code generated for Ada.Direct_Io (body) in file a-direio.adb"

[The non-capitalization of _Io is interesting, but that's just
a passing point.]

Other Ada bodies generally compile OK.  I suspect that the
problem here is my trying to compile an "Ada." package, but I
don't know why that's a problem.

Incidentally, the reason I'm trying to recompile Ada.Direct_IO
is that the Public Ada Library Card Catalog program doesn't
work under GNAT NT.  It appears to be choking on a control-Z
in a binary input file; the direct I/O files are being opened
in text mode by the Direct_IO package.  I'm trying to hack
around the problem.

Thanks for any help,

Mark R  a newcomer to Ada



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

* Re: GNAT NT & Ada.Direct_IO
  1995-01-09  4:33 GNAT NT & Ada.Direct_IO Mark Riordan
@ 1995-01-09  6:07 ` Robert Dewar
  1995-01-09  6:10 ` Robert Dewar
  1995-01-09 21:43 ` Michael Feldman
  2 siblings, 0 replies; 9+ messages in thread
From: Robert Dewar @ 1995-01-09  6:07 UTC (permalink / raw)


Mark, please be sure to send basic questions like this to gnat-report
where they will get answered immediately.

THe answer to your question about direct_io is trivial, it is a generic unit,
and compiling generic units, like compiling specs, with GNAT does not
generate code.

It is only when a generic is instantiated that code is generated.

Actually in the case of generics, but not package specs, it is conceivable
that this will change in the future. Note also that there is a current
bug which causes a null object file to be generated for generics.

But anyway, the bottom line for the moment is use the -gnatc when
compiling generics, since no code is generated. THe only reason for
compiling a generic unit like direct_io is to check it out semantically.

P.S. the capitlization is because this particular error message always
generates mixed case output. It is too much trouble to copy the actual
capitalization from he source in this particular case.




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

* Re: GNAT NT & Ada.Direct_IO
  1995-01-09  4:33 GNAT NT & Ada.Direct_IO Mark Riordan
  1995-01-09  6:07 ` Robert Dewar
@ 1995-01-09  6:10 ` Robert Dewar
  1995-01-09 21:43 ` Michael Feldman
  2 siblings, 0 replies; 9+ messages in thread
From: Robert Dewar @ 1995-01-09  6:10 UTC (permalink / raw)


Note incidentally that it is generally "not permitted" to recompile
children of Ada, Interfaces and System, in accordance with the permission
in the RM.

This restriction can be bypassed by the use of the -gnatg option, but then
you must follow the GNAT style restrictions (documented in the body of
the module style.adb)




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

* Re: GNAT NT & Ada.Direct_IO
  1995-01-09  4:33 GNAT NT & Ada.Direct_IO Mark Riordan
  1995-01-09  6:07 ` Robert Dewar
  1995-01-09  6:10 ` Robert Dewar
@ 1995-01-09 21:43 ` Michael Feldman
  1995-01-10  4:55   ` Mark Riordan
  2 siblings, 1 reply; 9+ messages in thread
From: Michael Feldman @ 1995-01-09 21:43 UTC (permalink / raw)


In article <3eqe9u$n0b@msunews.cl.msu.edu>,
Mark Riordan <mrr@scss3.cl.msu.edu> wrote:
>When I run:
>
>   gcc -c a-direio.adb
>
>I am surprised to get the message:
>
>"No code generated for Ada.Direct_Io (body) in file a-direio.adb"

Perhaps NYU will answer your question more articulately than I,
but in fact GNAT does not generate code when a _generic_ (like 
Direct_IO) is compiled. The syntactic and semantic checking is
done, but the code is not generated till the generic unit is
instantiated.

[snip]

>Incidentally, the reason I'm trying to recompile Ada.Direct_IO
>is that the Public Ada Library Card Catalog program doesn't
>work under GNAT NT.  It appears to be choking on a control-Z
>in a binary input file; the direct I/O files are being opened
>in text mode by the Direct_IO package.  I'm trying to hack
>around the problem.

Hmmm - better let NYU handle this one. But the "no code generated"
is a normal GNAT message when a generic is compiled. 

Have you reported this to gnat-report@cs.nyu.edu? If not, please do.

Mike Feldman
------------------------------------------------------------------------
Michael B. Feldman -  chair, SIGAda Education Working Group
Professor, Dept. of Electrical Engineering and Computer Science
The George Washington University -  Washington, DC 20052 USA
202-994-5919 (voice) - 202-994-0227 (fax) - mfeldman@seas.gwu.edu (Internet)
------------------------------------------------------------------------
One, two, three ways an underdog: Ada fan, Mac fan, Old Liberal Democrat
------------------------------------------------------------------------
         Ada on the World-Wide Web: http://lglwww.epfl.ch/Ada/
------------------------------------------------------------------------



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

* Re: GNAT NT & Ada.Direct_IO
  1995-01-09 21:43 ` Michael Feldman
@ 1995-01-10  4:55   ` Mark Riordan
  0 siblings, 0 replies; 9+ messages in thread
From: Mark Riordan @ 1995-01-10  4:55 UTC (permalink / raw)


Thanks to Michael Feldman and Robert Dewar for responding to
my question on recompiling Ada.Direct_IO.  I see I have some
things to learn about "instantiation".

I now know about gnat-report@cs.nyu.edu and have sent a message
to them.  

Regarding the Public Ada Library:  in response to email questions
I received, this is available from wuarchive.wustl.edu:/languages/ada.
It appears to be a very substantial library of Ada programs,
with good indexing.
I haven't yet figured out a way to get the "Card Catalog" program
to work under NT.  There is a precompiled DOS version which would
probably run under NT, but I want to compile it myself, by golly...

Mark R



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

* Re: GNAT NT & Ada.Direct_IO
       [not found] <INFO-ADA%95011109284406@VM1.NODAK.EDU>
@ 1995-01-12 13:57 ` Robert Dewar
  1995-01-12 15:58 ` Tom Griest
  1 sibling, 0 replies; 9+ messages in thread
From: Robert Dewar @ 1995-01-12 13:57 UTC (permalink / raw)


Marin Condic suggests that GNAT display version and bug information etc.
always, in listings, and on errors.

I don't want to do it always, that would be too annoying to most users
I think ??? Of course there is a verbose option now that displays the
version (-gnatv) and it is not a bad idea to make this also print the
send bug information to message. Right now, -gnatv gives:

NYU GNAT Compiler Version 2.01w (C) Copyright NYU, 1992,1993,1994

for example.

We do give full information on submitting bugs if a bomb occurs that we can
intercept. Right now we are not intercepting signals, which is unfortuate,
and we are trying to fix this obvious shortcoming.

Program listings (obtained with the -gnatl option) also contain the version
information, and could perhaps include the send bug information message.

I am a little reluctant actually to unconditionally output this on listings,
because then all students see this message, and we already get too many
messages from beginning students asking us how Ada works :-)  This morning
I got a message which roughly said:

 "I am very enthusiastic about Ada 9X, and I understand it has object
  oriented facilities, can you please email me a complete description
  of how these are used".

:-)




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

* Re: GNAT NT & Ada.Direct_IO
       [not found] <INFO-ADA%95011109284406@VM1.NODAK.EDU>
  1995-01-12 13:57 ` Robert Dewar
@ 1995-01-12 15:58 ` Tom Griest
  1 sibling, 0 replies; 9+ messages in thread
From: Tom Griest @ 1995-01-12 15:58 UTC (permalink / raw)


In article <INFO-ADA%95011109284406@VM1.NODAK.EDU> CONDIC@PSAVAX.PWFL.COM writes
>>
>[..snip...], but what would be wrong with having the compiler print out an
>identification line or two whenever it is invoked and include all
>the pertinent information about versions, etc. and include the
>"send all bug reports to..." info as well.
>
>Or have this printed out in program listings or when fatal errors
>occur, or...?
>

Most people don't like messages every time the compiler is invoked.
GNAT will print out an identification line, but you have to use the
switch  -v   (for gcc) and -gnatv (for gnat1).  I don't understand
the comment about printing out "send all bug reports to..." on fatal
errors, because GNAT already does this if it detects a compiler bug.
As for user bugs, I don't think you want to send those in do you?
In any case, the LabTek NT release comes with on-line help in the
standard MS ".hlp" file which is invoked by typing "gcc -help"
(If you type in any unrecognized switch, gcc will tell you how
to invoke help.)  In the help, there is clear information about
how to submit bug reports.  On the title screen click on "What to
do if you have problems".   I guess this might be another case of
RTFM?


-Tom



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

* Re: GNAT NT & Ada.Direct_IO
@ 1995-01-13 15:43 CONDIC
  1995-01-14  2:35 ` David Weller
  0 siblings, 1 reply; 9+ messages in thread
From: CONDIC @ 1995-01-13 15:43 UTC (permalink / raw)


From: Marin David Condic, 407.796.8997, M/S 731-93
Subject: Re: GNAT NT & Ada.Direct_IO
Original_To:  PROFS%"SMTP@PWAGPDB"
Original_cc:  CONDIC



Robert Dewar <dewar@CS.NYU.EDU> writes:
>
>I don't want to do it always, that would be too annoying to most users
>I think ??? Of course there is a verbose option now that displays the
>
Lots of products put out copyright notices, product info, etc.
every time they fire up. It may be annoying, but I think most of
us are used to it by now. Besides, on a command line based
application, a couple of lines of output has very little, if any,
impact on your life. (Doesn't really slow anything down, eh?) It
might be better to make this the default mode and include a
-quiet switch, rather than a -verbose switch. That way, you're
sure the user has seen the notice at least once.

>
>I am a little reluctant actually to unconditionally output this on listings,
>because then all students see this message, and we already get too many
>
Well, unfortunately, you can't have it both ways. A well
publicized e-address for registering bug reports, etc. cures the
problem of people not knowing where to send the reports. It will
also have the consequence of increasing the junk-mail.

You might consider having a canned response which is
automatically sent back to every submitter - something like "We
get tons of mail, so we don't have time to answer all the
bonehead questions. Here's a FAQ which will probably point you in
the right direction and we'll ignore you if your question was
addressed in the FAQ. And oh, by the way, check out this file of
closed out bug reports periodically to see if your's was dealt
with - otherwise leave us alone. You should be glad we bothered
to give you any software at all, so bellyaching over our
unwillingness to take a deep personal interest in your piddly
little problems isn't going to do much good. So sit down, stop
your whining and get back to work!"

You might consider making the response a bit more diplomatic. I'm
not destined for an exciting new career in customer relations.

Pax,
Marin

Marin David Condic, Senior Computer Engineer    ATT:        407.796.8997
M/S 731-93                                      Technet:    796.8997
Pratt & Whitney, GESP                           Internet:   CONDICMA@PWFL.COM
P.O. Box 109600                                 Internet:   MDCONDIC@AOL.COM
West Palm Beach, FL 33410-9600
===============================================================================
    "If nobody else was violent, I could conquer the whole stupid
    planet with a butter knife"

        -- Dogbert
===============================================================================



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

* Re: GNAT NT & Ada.Direct_IO
  1995-01-13 15:43 CONDIC
@ 1995-01-14  2:35 ` David Weller
  0 siblings, 0 replies; 9+ messages in thread
From: David Weller @ 1995-01-14  2:35 UTC (permalink / raw)


This entire conversation sounds like a plea for somebody to write a
GNAT-FAQ.

Also, IMHO, there is NOTHING wrong with having the last line of a
GNAT error report (just after the ubiquitous "Compilation abandoned")
say:

Problems?  Bug reports and pleas for help to: gnat-report@cs.nyu.edu

Just my $0.02 -- now back to my struggle with GNAT...

-- 
       Frustrated with C/C++, Pascal, Fortran?  Ada95 _might_ be for you!
	  For all sorts of interesting Ada95 tidbits, run the command:
"finger dweller@starbase.neosoft.com | more" (or e-mail with "finger" as subj.)
	



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

end of thread, other threads:[~1995-01-14  2:35 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1995-01-09  4:33 GNAT NT & Ada.Direct_IO Mark Riordan
1995-01-09  6:07 ` Robert Dewar
1995-01-09  6:10 ` Robert Dewar
1995-01-09 21:43 ` Michael Feldman
1995-01-10  4:55   ` Mark Riordan
     [not found] <INFO-ADA%95011109284406@VM1.NODAK.EDU>
1995-01-12 13:57 ` Robert Dewar
1995-01-12 15:58 ` Tom Griest
  -- strict thread matches above, loose matches on Subject: below --
1995-01-13 15:43 CONDIC
1995-01-14  2:35 ` David Weller

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