From: Robert A Duff <bobduff@shell01.TheWorld.com>
Subject: Re: How to detect OS type and version?
Date: 16 Oct 2005 11:59:57 -0400
Date: 2005-10-16T11:59:57-04:00 [thread overview]
Message-ID: <wccwtkdo3k2.fsf@shell01.TheWorld.com> (raw)
In-Reply-To: ufyr2dqf1.fsf@STRIPCAPStelus.net
Ray Blaak <rAYblaaK@STRIPCAPStelus.net> writes:
> What I would do in your case is to make my own project-specific enumerated
> type and decide the appropriate current literal value at startup based on the
> the string-based values returned from querying the OS.
In my case, we have an enumeration type, and we compile in the value.
(That is, we have a package spec with three versions, and the build
scripts pick the right one.) There's no need to query anything at run
time (in my project).
> I guess what I care about is that the built in OS query that would live
> somewhere under the System or Ada hierarchy would not return an enumerated
> type, but rather a string.
>
> That is, the enumeration should not be built into the language, since
> it is not at all a stable enough set of values for the long
> term. Imagine being able to code to an updated set only every 10
> years, which seems to be Ada's upgrade cycle.
I agree that an enum type would not work here, as a language feature.
But neither would a string or anything else -- there is no solution
at the language level. This issue has to be solved by each project,
I think.
- Bob
next prev parent reply other threads:[~2005-10-16 15:59 UTC|newest]
Thread overview: 37+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-10-13 2:35 How to detect OS type and version? Roger Blum
2005-10-13 6:05 ` Martin Dowie
2005-10-13 9:50 ` Stefan Bellon
2005-10-13 10:39 ` Martin Dowie
2005-10-13 18:12 ` Jeffrey R. Carter
2005-10-13 18:37 ` Stefan Bellon
2005-10-13 21:21 ` Robert A Duff
2005-10-13 21:25 ` Stefan Bellon
2005-10-13 21:52 ` Robert A Duff
2005-10-16 0:13 ` Ray Blaak
2005-10-16 0:29 ` Robert A Duff
2005-10-16 4:48 ` Ray Blaak
2005-10-16 14:16 ` Larry Kilgallen
2005-10-16 15:55 ` Robert A Duff
2005-10-16 20:06 ` Pascal Obry
2005-10-18 16:58 ` Ray Blaak
2005-10-16 15:59 ` Robert A Duff [this message]
2005-10-17 17:19 ` Ray Blaak
2005-10-13 18:11 ` Jeffrey R. Carter
2005-10-13 19:44 ` Simon Wright
2005-10-13 21:04 ` Michael Bode
2005-10-14 1:33 ` Steve
2005-10-13 12:06 ` Rob Norris
2005-10-13 11:59 ` Martin Dowie
2005-10-14 0:21 ` Randy Brukardt
2005-10-14 8:02 ` Martin Dowie
2005-10-14 23:27 ` Randy Brukardt
2005-10-15 12:28 ` Larry Kilgallen
2005-10-15 14:12 ` Martin Dowie
2005-10-14 9:52 ` Rob Norris
2005-10-13 20:25 ` Bernd Specht
2005-10-13 20:36 ` Michael Bode
2005-10-13 20:41 ` Bernd Specht
2005-10-13 20:58 ` Stefan Bellon
2005-10-14 0:27 ` Randy Brukardt
2005-10-15 19:48 ` Bernd Specht
2005-10-14 6:30 ` Roger Blum
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox