From: Dmitry A. Kazakov <mailbox@dmitry-kazakov.de>
Subject: Re: Ada to 'C' parameter passing problem
Date: Thu, 20 Feb 2003 10:43:44 +0100
Date: 2003-02-20T10:43:44+01:00 [thread overview]
Message-ID: <vd895vg64rmr0971trsp4dnbgfqspc5r8e@4ax.com> (raw)
In-Reply-To: cf2c6063.0302200118.63a7ea1d@posting.google.com
On 20 Feb 2003 01:18:34 -0800, rod.chapman@praxis-cs.co.uk (Rod
Chapman) wrote:
>mheaney@on2.com (Matthew Heaney) wrote in message news:> That Ada doesn't allow you to specify inout mode for function
>> parameters is a deficiency of Ada...
>
>Wow! This reflects somewhat of a gulf between our respective
>views of language design! (Don't get me wrong, neither position
>is necessarily right or wrong, just different...)
>
>At the SPARK end of the spectrum functions calls are expressions
>which return a value and never have a side-effect. Procedure
>calls are statements which have side-effects - A rather
>significant _semantic_ difference!
>
>If you do prefer the ability to allow a function to modify its
>parameters, then it should at least be good enough to confess
>this to the outside-world as part of its specifiction. The current
>discussion for Ada0Y in AI231 (extending anonymous access
>parameters) is welcome here, especially from a static-analysis
>point of view.
[ Long awaited thread "inout parameters for functions" is again here
(:-)) ]
"To return a value via the result parameter" /= "To have no side
effects other than on the out and inout parameters"
To mix the above two is definitely a deficiency. To involve pointers
as a work-around for consequences of that deficiency is worse than
just a deficiency.
---
Regards,
Dmitry Kazakov
www.dmitry-kazakov.de
next prev parent reply other threads:[~2003-02-20 9:43 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-02-18 15:39 Ada to 'C' parameter passing problem Patrick
2003-02-18 16:47 ` Jeffrey Carter
2003-02-18 19:50 ` Rod Chapman
2003-02-20 2:36 ` Matthew Heaney
2003-02-20 9:18 ` Rod Chapman
2003-02-20 9:43 ` Dmitry A. Kazakov [this message]
2003-02-20 22:05 ` Simon Wright
2003-02-21 9:53 ` Stuart Palin
2003-02-21 17:39 ` Jeffrey Carter
2003-02-21 18:12 ` Warren W. Gay VE3WWG
2003-02-21 20:25 ` Randy Brukardt
2003-02-24 23:53 ` Matthew Heaney
2003-02-25 17:21 ` Rod Chapman
-- strict thread matches above, loose matches on Subject: below --
2003-02-21 16:52 Lionel.DRAGHI
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox