Dan Cross wrote in
<CAEoi9W63J0HKbWUk8wrGSkCdyzzaV-F6km-q+K-H2+kvURWWdQ(a)mail.gmail.com>:
|On Tue, Dec 1, 2020 at 3:40 PM Bakul Shah <bakul(a)iitbombay.org> wrote:
|
|> On Dec 1, 2020, at 12:20 PM, Steffen Nurpmeso <steffen(a)sdaoden.eu> wrote:
|>> Never without my goto:, and if it is only to break to error
|>> handling and/or staged destruction of local variables after
|>> initialization failures. Traumatic school impression, finding
|>> yourself locked in some PASCAL if condition, and no way to go to.
|>
|> Pascal had goto.
Hm, i did not receive Bakul's mail. Well i did not use it long
enough. I think this came up in the past already, it could have
been it was a mutilated version, there definetely was no goto in
this DOS-looking UI with menu bar, with menu entries for
compilation plus, help screen etc etc. Borland Pascal, Borland
dBASE it must have been then. Didn't i say "maybe the teacher had
an option to turn it on" or something :) Yeah, i do not know, but
there was no goto, definetely.
|Pascal also had to go. (Thanks...I'm here all week.)
Ah, and all the many-page program listings in Delphi, what a waste
of paper. Whether anyone really typed them out, not me.
|You can even do a non-local goto!
Help.
|> In Go you don't need goto for the sort of thing you and McVoy
|> talked about due to its defer statement and GC. Now granted
|> GC may be too big of a hammer for C/C++ but a future C/C++
|> add defer gainfully as the defer pattern is pretty common.
|> For example, mutex lock and unlock.
Terrible just as pthread_cleanup_push/pop, and that can be
entirely local-to-scope. Terrible even if there would be
"closure"s that could be used as arguments instead of a function
pointer. gcc supports/ed computed goto's, which would also be
nice in that respect. And some kind of ISO _Xy() which could be
used in conditionals dependent on whether the argument is
a computed goto, a "closure" or a function pointer (or a member
function pointer).
I always hated that C++ is not ISO C plus extensions, so your
"C/C++" is not true for a long time...
--steffen
|
|Der Kragenbaer, The moon bear,
|der holt sich munter he cheerfully and one by one
|einen nach dem anderen runter wa.ks himself off
|(By Robert Gernhardt)
Show replies by date
Steffen Nurpmeso wrote in
<20201201223824.gBVRZ%steffen(a)sdaoden.eu>:
|Dan Cross wrote in
| <CAEoi9W63J0HKbWUk8wrGSkCdyzzaV-F6km-q+K-H2+kvURWWdQ(a)mail.gmail.com>:
||On Tue, Dec 1, 2020 at 3:40 PM Bakul Shah <bakul(a)iitbombay.org> wrote:
||> On Dec 1, 2020, at 12:20 PM, Steffen Nurpmeso <steffen(a)sdaoden.eu> \
||> wrote:
||>> Never without my goto:, and if it is only to break to error
||>> handling and/or staged destruction of local variables after
||>> initialization failures. Traumatic school impression, finding
||>> yourself locked in some PASCAL if condition, and no way to go to.
||>
||> Pascal had goto.
|
|Hm, i did not receive Bakul's mail. Well i did not use it long
Actually not true.
Dec 1 21:39:30 postfix/qmgr[2670]: 4557B16056: from=<bakul(a)iitbombay.org>,
size=4251, nrcpt=1 (queue active)
Dec 1 21:39:30 postfix/local[9475]: 4557B16056: to=<steffen(a)sdaoden.eu>,
relay=local, delay=0.11, delays=0.08/0/0/0.02, dsn=2.0.0, status=sent (delivered to
mailbox)
...
|Help.
And increasingly so.
--steffen
|
|Der Kragenbaer, The moon bear,
|der holt sich munter he cheerfully and one by one
|einen nach dem anderen runter wa.ks himself off
|(By Robert Gernhardt)