comp.lang.ada
 help / color / mirror / Atom feed
From: "Adrian P. Morgan" <apmorgan@ist.flinders.edu.au>
Subject: Re: Assertions in Ada
Date: 1997/08/27
Date: 1997-08-27T00:00:00+00:00	[thread overview]
Message-ID: <34036C83.4AA6@ist.flinders.edu.au> (raw)
In-Reply-To: dewar.872559855@merv


I'm only a student, so I might be talking utter rubbish, but I find all
this rather interesting so here goes...

As an alternative to using a pragma as an assertion mechanism, would it
be possible to add new attributes to subprograms such as 'Precondition?
Then we could say,

for P'Precondition use Boolean_Expression;
for P'Postcondition use Boolean_Expression;
for P'Time_Constraint use 3.0; -- alternative to select then abort

If only to aid my personal understanding of what assertions are all
about (IIUC they are a mechanism for conditionalising the execution of a
subprogram from within the specification), I would appreciate mailed
comments on the above.

-- 

 _____________________________________________
/ Adrian Morgan <apmorgan@ist.flinders.edu.au>\
===============================================----------------------
| Studies:   2nd year BSc(Computing) at Flinders University in 1997 |
| Residence: Bible College of South Australia residential community |
| Interests: Science, Theology, Programming, SF, Comedy, Music, etc |
| Mail:      Welcome                                                |
---------------------------------------------------------------------




  reply	other threads:[~1997-08-27  0:00 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1997-08-21  0:00 Assertions in Ada AdaWorks
1997-08-21  0:00 ` Tucker Taft
1997-08-21  0:00   ` Brian Rogoff
1997-08-22  0:00     ` Robert Dewar
     [not found]   ` <JSA.97Aug21183650@alexandria.organon.com>
1997-08-21  0:00     ` Robert Dewar
1997-08-22  0:00       ` Tucker Taft
1997-08-23  0:00         ` Ken Garlington
1997-08-24  0:00           ` Brian Rogoff
     [not found]         ` <199708251351.PAA13197@basement.replay.com>
1997-08-25  0:00           ` Robert Dewar
1997-08-27  0:00             ` Adrian P. Morgan [this message]
1997-08-31  0:00               ` Robert A Duff
1997-08-23  0:00   ` Ken Garlington
1997-08-24  0:00     ` Robert Dewar
  -- strict thread matches above, loose matches on Subject: below --
1997-08-22  0:00 AdaWorks
replies disabled

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