comp.lang.ada
 help / color / mirror / Atom feed
From: "Björn Lundin" <b.f.lundin@gmail.com>
Subject: Re: Put the access value
Date: Thu, 23 Apr 2020 13:37:19 +0200
Date: 2020-04-23T13:37:19+02:00	[thread overview]
Message-ID: <r7rulf$ahr$1@dont-email.me> (raw)
In-Reply-To: <7cef829e-430e-4dec-b12d-f13edfd86ebc@googlegroups.com>

Den 2020-04-22 kl. 19:33, skrev AdaMagica:
> Am Mittwoch, 22. April 2020 14:31:11 UTC+2 schrieb björn lundin:
>> I do agree, but the tone of AdaMagica is more like a professor telling a
>> student what to do or not.
> 
> I appoligize if my answer made this impression - this was not my intent.

Through the written media it is sometimes hard to express intonations 
and it is sometimes hard to interpret the underlying tone of a message.
I could have been more forgiving in my reply,
and it is nice to know that the tone i read into it was not there.


> My thinking was: Someone not using GNAT might think "Oh, that's nice, I'll remember" and later "WTF? Isn't Ada always praised for its portability?"

Well that is true only so far.

While i do agree with Randy that is is good to state the compiler,
I don't think failure to do so should be rewarded with a
'you should have done that'

And is it really enough to say it's gnat?


I don't think the version of the language was mentioned
  (83/95/05/12/15/2x)
(does both 15 and 12 exist?)
I have had case where my collegues used 'Img (gnat-specifik) and
then changed it to 'Image - part of a newer standard - for portability.

Then that code has been moved to another project, where it fails to 
compile. That used gnat 7.4.2, which is 2012. but not 2015. And only
the gnat specific attribute works there.
And here I hear people say 'use type'image(varible) instead.

But I do think

Assignment_Id'image or Assignment_Id'Img is nicer than

with Core_Types
...
Core_Types.Assignment_Identity_Type'Image(Assignment_Id)

which we did before to log out an Assignment_Id


Another thing if working with operating system is the compiler's
runtime tasking model.

A piece of code using blocking calls for I/O in a thread will
work well on implementations mapping tasks to os-threads,
but will block the whole process if the tasking is made by the compiler 
runtime. Alysy Ada did that on AIX (Ada 83). And I think Janus as well.
Object Ada (I think) and Gnat does not.

There are likely other things that break portability

So, should one state language version and runtime behaviour too?


> And there is that habit of many equalling GNAT and Ada (for instance claiming that body files must have the extension adb - even with GNAT, that isn't the case).

Yes, and that is unfortunate.
But critisizing other helpful posts does not change that.
If the OP would have tried the gnat-specific advice given, and failed,
he/she would likely have come back and said 'no good'


-- 
Björn

      reply	other threads:[~2020-04-23 11:37 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-14  7:15 Put the access value ldries46
2020-04-14  7:42 ` J-P. Rosen
2020-04-18 15:08   ` Oliver Kellogg
2020-04-20 23:02   ` Robert A Duff
2020-04-21  7:07     ` briot.emmanuel
2020-04-21 22:29       ` Robert A Duff
2020-04-14 11:05 ` Jeffrey R. Carter
2020-04-14 12:09   ` ldries46
2020-04-15  7:20     ` briot.emmanuel
2020-04-15  8:02       ` AdaMagica
2020-04-15  8:51         ` J-P. Rosen
2020-04-15 16:23           ` AdaMagica
2020-04-17 14:20         ` Björn Lundin
2020-04-21 21:06           ` Randy Brukardt
2020-04-22 12:31             ` Björn Lundin
2020-04-22 17:33               ` AdaMagica
2020-04-23 11:37                 ` Björn Lundin [this message]
replies disabled

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