From: "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de>
Subject: Re: Unary operator after binary operator: legal or not? => Compiler Error
Date: Tue, 31 Jul 2007 19:52:10 +0200
Date: 2007-07-31T19:52:10+02:00 [thread overview]
Message-ID: <g6d631ru7n28.14hgnvwzvo6uy.dlg@40tude.net> (raw)
In-Reply-To: wccy7gwa7sh.fsf@shell01.TheWorld.com
On Tue, 31 Jul 2007 11:53:50 -0400, Robert A Duff wrote:
> But don't you think:
>
> X * -3
>
> ought to be legal (no user-defined operators in sight)?
Maybe it was a typing error of:
X * Y - 3
If not, then probably it is a style error:
- X * 3
I find Ada's association restrictions a god idea. In earlier days C/C++
liberal policy of handling associations was a real problem. Nowadays, one
gets a warning in some cases, but Ada is far stricter and for all I think
that the idea of warning is itself not OK. Ideally, any program should be
either legal or not. Nothing in between. Any warning is a kind of defeat in
language design.
Of course if we considered -3 being a literal, that would change a lot. But
that would be IMO a bad idea.
BTW, following the reductionist's path, what about eliminating decimal
literals, introducing "." and "E" operators instead?
function "." (Numerator, Denominator : Universal_Integer)
return Universal_Real;
(:-))
--
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de
next prev parent reply other threads:[~2007-07-31 17:52 UTC|newest]
Thread overview: 39+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-07-30 22:52 Unary operator after binary operator: legal or not? Jeffrey R. Carter
2007-07-30 23:39 ` Markus E.L.
2007-07-31 0:22 ` Adam Beneschan
2007-07-31 21:52 ` Jeffrey R. Carter
2007-07-31 8:01 ` anon
2007-07-31 8:16 ` Unary operator after binary operator: legal or not? => Compiler Error anon
2007-07-31 8:38 ` AW: Unary operator after binary operator: legal or not? => CompilerError Grein, Christoph (Fa. ESG)
2007-07-31 15:05 ` Unary operator after binary operator: legal or not? => Compiler Error Robert A Duff
2007-07-31 15:39 ` Dmitry A. Kazakov
2007-07-31 15:53 ` Robert A Duff
2007-07-31 17:02 ` Georg Bauhaus
2007-07-31 19:17 ` Adam Beneschan
2007-08-01 7:16 ` Maciej Sobczak
2007-08-01 15:23 ` Adam Beneschan
2007-07-31 20:59 ` Robert A Duff
2007-08-01 7:24 ` Georg Bauhaus
2007-08-01 8:02 ` Dmitry A. Kazakov
2007-08-01 8:17 ` AW: Unary operator after binary operator: legal or not? => CompilerError Grein, Christoph (Fa. ESG)
2007-08-01 10:10 ` Ian Clifton
2007-08-01 9:34 ` Unary operator after binary operator: legal or not? => Compiler Error Georg Bauhaus
2007-08-01 21:51 ` Jeffrey R. Carter
2007-07-31 17:52 ` Dmitry A. Kazakov [this message]
2007-08-02 20:44 ` Charles Lindsey
2007-08-03 7:48 ` Stuart
2007-08-03 7:51 ` Dmitry A. Kazakov
2007-07-31 23:22 ` anon
2007-08-01 0:13 ` Adam Beneschan
2007-08-01 6:20 ` Unary operator after binary operator: legal or not? => Illegal anon
2007-08-01 5:34 ` AW: Unary operator after binary operator: legal or not? => CompilerError Grein, Christoph (Fa. ESG)
2007-08-01 6:46 ` To := Grein, Christoph (Fa. ESG) anon
2007-08-01 7:11 ` AW: " Grein, Christoph (Fa. ESG)
2007-08-02 6:52 ` anon
2007-08-02 8:56 ` AW: " Grein, Christoph (Fa. ESG)
2007-08-02 22:29 ` Markus E.L. 2
2007-08-02 23:02 ` tmoran
2007-08-02 23:11 ` Ed Falis
2007-08-02 23:34 ` Markus E.L. 2
2007-08-03 4:42 ` AW: " Grein, Christoph (Fa. ESG)
2007-08-02 22:28 ` Markus E.L. 2
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox