* ADA.CALENDAR.TIME_OF problem with cygwin gcc-ada
@ 2004-06-18 16:04 Roger Blum
2004-06-18 18:30 ` Frank J. Lhota
` (2 more replies)
0 siblings, 3 replies; 9+ messages in thread
From: Roger Blum @ 2004-06-18 16:04 UTC (permalink / raw)
Hi everybody,
I 'd like to use the function TIME_OF in the package ADA.CALENDAR to convert
a date/time (string format from database "DD.MM.YYYY HH:MI:SS") to a TIME
type in order to calculate intervals between dates etc.
Although I call the TIME_OF function with correct input, it raises a
CONSTRAINT ERROR (I'm using gcc-ada from cygwin).
Anybody any idea what the problem is and how I can solve it?
Thanks.
Roger
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: ADA.CALENDAR.TIME_OF problem with cygwin gcc-ada
2004-06-18 16:04 ADA.CALENDAR.TIME_OF problem with cygwin gcc-ada Roger Blum
@ 2004-06-18 18:30 ` Frank J. Lhota
2004-06-18 19:24 ` Roger Blum
2004-06-19 2:21 ` Brian May
2004-06-19 6:15 ` Simon Wright
2 siblings, 1 reply; 9+ messages in thread
From: Frank J. Lhota @ 2004-06-18 18:30 UTC (permalink / raw)
"Roger Blum" <roger.blum@armasuisse.ch> wrote in message
news:40d31280@news.admin.ch...
> Hi everybody,
>
> I 'd like to use the function TIME_OF in the package ADA.CALENDAR to
convert
> a date/time (string format from database "DD.MM.YYYY HH:MI:SS") to a TIME
> type in order to calculate intervals between dates etc.
> Although I call the TIME_OF function with correct input, it raises a
> CONSTRAINT ERROR (I'm using gcc-ada from cygwin).
>
> Anybody any idea what the problem is and how I can solve it?
>
> Thanks.
>
> Roger
The problem is that the Ada compiler that comes with Cygwin is seriously
flawed. The solution is to download and use the latest GNAT public release
(version 3.15p). I could not re-create the problem with this compiler.
It is a shame that the first Ada compiler distributed with Cygwin was not
better.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: ADA.CALENDAR.TIME_OF problem with cygwin gcc-ada
2004-06-18 18:30 ` Frank J. Lhota
@ 2004-06-18 19:24 ` Roger Blum
2004-06-22 13:55 ` Peter Hermann
0 siblings, 1 reply; 9+ messages in thread
From: Roger Blum @ 2004-06-18 19:24 UTC (permalink / raw)
Hi Frank,
Thanks for your reply.
I 've used GNAT 3.15p before. I was urged to change to cygwin Ada because I
have to link my project with some c++ libraries, which isn't supported by
GNAT 3.15p (means I haven't found a way to do it).
I suppose I have to write my own calendar package to do the date
calculations.
"Frank J. Lhota" <NOSPAM.lhota.adarose@verizon.net> schrieb im Newsbeitrag
news:axGAc.1551$z24.1074@nwrdny01.gnilink.net...
> "Roger Blum" <roger.blum@armasuisse.ch> wrote in message
> news:40d31280@news.admin.ch...
> > Hi everybody,
> >
> > I 'd like to use the function TIME_OF in the package ADA.CALENDAR to
> convert
> > a date/time (string format from database "DD.MM.YYYY HH:MI:SS") to a
TIME
> > type in order to calculate intervals between dates etc.
> > Although I call the TIME_OF function with correct input, it raises a
> > CONSTRAINT ERROR (I'm using gcc-ada from cygwin).
> >
> > Anybody any idea what the problem is and how I can solve it?
> >
> > Thanks.
> >
> > Roger
>
> The problem is that the Ada compiler that comes with Cygwin is seriously
> flawed. The solution is to download and use the latest GNAT public release
> (version 3.15p). I could not re-create the problem with this compiler.
>
> It is a shame that the first Ada compiler distributed with Cygwin was not
> better.
>
>
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: ADA.CALENDAR.TIME_OF problem with cygwin gcc-ada
2004-06-18 16:04 ADA.CALENDAR.TIME_OF problem with cygwin gcc-ada Roger Blum
2004-06-18 18:30 ` Frank J. Lhota
@ 2004-06-19 2:21 ` Brian May
2004-06-19 19:14 ` Roger Blum
2004-06-19 6:15 ` Simon Wright
2 siblings, 1 reply; 9+ messages in thread
From: Brian May @ 2004-06-19 2:21 UTC (permalink / raw)
>>>>> "Roger" == Roger Blum <roger.blum@armasuisse.ch> writes:
Roger> I 'd like to use the function TIME_OF in the package
Roger> ADA.CALENDAR to convert a date/time (string format from
Roger> database "DD.MM.YYYY HH:MI:SS") to a TIME type in order to
Roger> calculate intervals between dates etc. Although I call the
Roger> TIME_OF function with correct input, it raises a CONSTRAINT
Roger> ERROR (I'm using gcc-ada from cygwin).
What time_of function is this? I can't see any that takes a string
as a parameter...
The only one I know of is this one:
function Time_Of
(Year : Year_Number;
Month : Month_Number;
Day : Day_Number;
Seconds : Day_Duration := 0.0)
return Time;
--
Brian May <bam@snoopy.apana.org.au>
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: ADA.CALENDAR.TIME_OF problem with cygwin gcc-ada
2004-06-18 16:04 ADA.CALENDAR.TIME_OF problem with cygwin gcc-ada Roger Blum
2004-06-18 18:30 ` Frank J. Lhota
2004-06-19 2:21 ` Brian May
@ 2004-06-19 6:15 ` Simon Wright
2004-06-19 10:51 ` Georg Bauhaus
2 siblings, 1 reply; 9+ messages in thread
From: Simon Wright @ 2004-06-19 6:15 UTC (permalink / raw)
"Roger Blum" <roger.blum@armasuisse.ch> writes:
> I 'd like to use the function TIME_OF in the package ADA.CALENDAR to
> convert a date/time (string format from database "DD.MM.YYYY
> HH:MI:SS") to a TIME type in order to calculate intervals between
> dates etc. Although I call the TIME_OF function with correct input,
> it raises a CONSTRAINT ERROR (I'm using gcc-ada from cygwin).
>
> Anybody any idea what the problem is and how I can solve it?
This is one that I reported! 9536 on 2003-02-01 against 3.4
experimental, but present in 3.3. Fixed 2003-10-21.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: ADA.CALENDAR.TIME_OF problem with cygwin gcc-ada
2004-06-19 6:15 ` Simon Wright
@ 2004-06-19 10:51 ` Georg Bauhaus
2004-06-19 19:16 ` Roger Blum
0 siblings, 1 reply; 9+ messages in thread
From: Georg Bauhaus @ 2004-06-19 10:51 UTC (permalink / raw)
Simon Wright <simon@pushface.org> wrote:
: "Roger Blum" <roger.blum@armasuisse.ch> writes:
:> Anybody any idea what the problem is and how I can solve it?
:
: This is one that I reported! 9536 on 2003-02-01 against 3.4
: experimental, but present in 3.3. Fixed 2003-10-21.
Mingw has a GCC 3.4.0 candidate release with an Ada compiler and with
a C++ compiler. Maybe this works better than the cygwin versions.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: ADA.CALENDAR.TIME_OF problem with cygwin gcc-ada
2004-06-19 2:21 ` Brian May
@ 2004-06-19 19:14 ` Roger Blum
0 siblings, 0 replies; 9+ messages in thread
From: Roger Blum @ 2004-06-19 19:14 UTC (permalink / raw)
"Brian May" <bam@snoopy.apana.org.au> schrieb im Newsbeitrag
news:sa4oengmgnc.fsf@snoopy.apana.org.au...
> >>>>> "Roger" == Roger Blum <roger.blum@armasuisse.ch> writes:
>
> Roger> I 'd like to use the function TIME_OF in the package
> Roger> ADA.CALENDAR to convert a date/time (string format from
> Roger> database "DD.MM.YYYY HH:MI:SS") to a TIME type in order to
> Roger> calculate intervals between dates etc. Although I call the
> Roger> TIME_OF function with correct input, it raises a CONSTRAINT
> Roger> ERROR (I'm using gcc-ada from cygwin).
>
> What time_of function is this? I can't see any that takes a string
> as a parameter...
>
> The only one I know of is this one:
>
> function Time_Of
> (Year : Year_Number;
> Month : Month_Number;
> Day : Day_Number;
> Seconds : Day_Duration := 0.0)
> return Time;
> --
> Brian May <bam@snoopy.apana.org.au>
It's of course the function mentioned by you. Before calling it I split and
convert the string accordingly.
Roger
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: ADA.CALENDAR.TIME_OF problem with cygwin gcc-ada
2004-06-19 10:51 ` Georg Bauhaus
@ 2004-06-19 19:16 ` Roger Blum
0 siblings, 0 replies; 9+ messages in thread
From: Roger Blum @ 2004-06-19 19:16 UTC (permalink / raw)
"Georg Bauhaus" <sb463ba@l1-hrz.uni-duisburg.de> schrieb im Newsbeitrag
news:cb15qp$gks$1@a1-hrz.uni-duisburg.de...
> Simon Wright <simon@pushface.org> wrote:
> : "Roger Blum" <roger.blum@armasuisse.ch> writes:
>
> :> Anybody any idea what the problem is and how I can solve it?
> :
> : This is one that I reported! 9536 on 2003-02-01 against 3.4
> : experimental, but present in 3.3. Fixed 2003-10-21.
>
> Mingw has a GCC 3.4.0 candidate release with an Ada compiler and with
> a C++ compiler. Maybe this works better than the cygwin versions.
Thanks for this hint. I'll try this one.
Roger
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: ADA.CALENDAR.TIME_OF problem with cygwin gcc-ada
2004-06-18 19:24 ` Roger Blum
@ 2004-06-22 13:55 ` Peter Hermann
0 siblings, 0 replies; 9+ messages in thread
From: Peter Hermann @ 2004-06-22 13:55 UTC (permalink / raw)
Roger Blum <roger_blum@swissonline.ch> wrote:
> I suppose I have to write my own calendar package to do the date
> calculations.
http://www.csv.ica.uni-stuttgart.de/homes/ph/adapilotresources/basic_tools/calenday.ads
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2004-06-22 13:55 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-06-18 16:04 ADA.CALENDAR.TIME_OF problem with cygwin gcc-ada Roger Blum
2004-06-18 18:30 ` Frank J. Lhota
2004-06-18 19:24 ` Roger Blum
2004-06-22 13:55 ` Peter Hermann
2004-06-19 2:21 ` Brian May
2004-06-19 19:14 ` Roger Blum
2004-06-19 6:15 ` Simon Wright
2004-06-19 10:51 ` Georg Bauhaus
2004-06-19 19:16 ` Roger Blum
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox