From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-1.1 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FROM,HTML_MESSAGE,MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 10914 invoked from network); 14 May 2020 00:43:38 -0000 Received: from minnie.tuhs.org (45.79.103.53) by inbox.vuxu.org with ESMTPUTF8; 14 May 2020 00:43:38 -0000 Received: by minnie.tuhs.org (Postfix, from userid 112) id 23FBD9C677; Thu, 14 May 2020 10:43:37 +1000 (AEST) Received: from minnie.tuhs.org (localhost [127.0.0.1]) by minnie.tuhs.org (Postfix) with ESMTP id 18C709C668; Thu, 14 May 2020 10:43:11 +1000 (AEST) Authentication-Results: minnie.tuhs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="GdWpottp"; dkim-atps=neutral Received: by minnie.tuhs.org (Postfix, from userid 112) id 252229C668; Thu, 14 May 2020 10:43:09 +1000 (AEST) Received: from mail-vs1-f46.google.com (mail-vs1-f46.google.com [209.85.217.46]) by minnie.tuhs.org (Postfix) with ESMTPS id 885119C604 for ; Thu, 14 May 2020 10:43:08 +1000 (AEST) Received: by mail-vs1-f46.google.com with SMTP id 1so954136vsl.9 for ; Wed, 13 May 2020 17:43:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=In3OelE99uOwi9aMYIJRkL54/l44A0HcqADl4Xqv+x0=; b=GdWpottpqpyE5yBNbQbYBMIt1hrp9PdBemtnJ3TgV5cOG+l5XLbg+6e4Czeit9Fxmr 9aliQz0bZBhjjNt8Q6F0Kn7WyCjMUAQMbKrlX0q89CBS/gtbsRDcj7S+AauS789fBvwL N3+7bwQb7m3mpzK2nTURou6xLMgV0iPNOA4QP2rn5bwYOkEC1f7Tol3O5tKm11SxlGcc N1M8xkRwl4OJ+35QdVeCIMQj2uPeC6pw5x4y14N+XtT5VtjWa1gZQkUkkI/qJbEfQt0k 1xPZaTD3DwAduTGI7mega/I6tWXG60lTDvD3YnSpAA9afrToJcwjFSGD63UjKKY73Okv 6bWw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=In3OelE99uOwi9aMYIJRkL54/l44A0HcqADl4Xqv+x0=; b=iX67DHuREWBqMxBXwiQcaaOrg8V1WfJRHnQkWLkFTcTcwgMrvvWIQkMrGQOAKR4GCx p7rZZn8s2tklasBLPV5LifmwaTDyI4b2TQy9xqHdGZkgnQPtuAtbMdjPO4W8+XjnPxSX 41Bxn4MjxioZotbD4q41wXmoRjp2RDJG8EfvjzF10ObZYnWbh/O/ifEH9MlmcQ74/9K5 9qzz6mfmdlrYpVZYshxIWB6B7kFeLjSdg5YyB9v2gebPvi72lcvFdJ6v09P2vvdC5s9M 6QyoXaxzhfqB6xGqYtkiyyKm0S8iJvVQO4KiCAdIPo7yDAqLe4707IKw8TPxF53EOMkC +S0g== X-Gm-Message-State: AOAM533wDdmoh3IEwPCSzENjObUte9vXOkXYLq16YygUyP26n5/lWQyS pgxBWxeogyQFlRycXfDVdOFDD0HkikYbG7Fx7qnVCmHf X-Google-Smtp-Source: ABdhPJxEDl31UCAcIpFnzeHCtw9GGe8yG6SWK0bsJW1JYRc6boyKkHxTq6ZkIYXRIDcz3ya4xQH//H2f+C5lm7RAl4c= X-Received: by 2002:a67:fc46:: with SMTP id p6mr1573007vsq.169.1589416987479; Wed, 13 May 2020 17:43:07 -0700 (PDT) MIME-Version: 1.0 References: <3cb1126796176debe28aa66672ba27ae@yaccman.com> <20200511005745.GL17035@mcvoy.com> <357EFE54-BD94-4C10-8C43-C6735BF7D317@via.net> <20200511202555.GU17035@mcvoy.com> In-Reply-To: From: "John P. Linderman" Date: Wed, 13 May 2020 20:42:55 -0400 Message-ID: To: Dave Horsfall Content-Type: multipart/alternative; boundary="000000000000f050e005a590fa12" Subject: Re: [TUHS] v7 K&R C X-BeenThere: tuhs@minnie.tuhs.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: The Unix Heritage Society mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: The Eunuchs Hysterical Society Errors-To: tuhs-bounces@minnie.tuhs.org Sender: "TUHS" --000000000000f050e005a590fa12 Content-Type: text/plain; charset="UTF-8" I never liked call by reference. When I was trying to understand a chunk of code, it was a great mental simplification to know that whatever a called routine did, it couldn't have an effect on the code I was trying to understand except through a returned value and (ghastly) global variables. Operator overloading is far worse. Now I can't even be sure code I'm looking at is doing what I thought it did. On Wed, May 13, 2020 at 7:38 PM Dave Horsfall wrote: > On Tue, 12 May 2020, Paul Winalski wrote: > > > Absolutely. The projects that I ran effectively used C++ as a > > stronger-typed version of C. A small subset of C++ features were > > allowed, but among the prohibited features were: > > [...] > > > o operator overloading > > [...] > > I never could figure out why Stroustrup implemented that "feature"; let's > see, this operator usually means this, except when you use it in that > situation in which case it means something else. Now, try debugging that. > > I had to learn C++ for a project at $WORK years ago (the client demanded > it), and boy was I glad when I left... > > -- Dave > --000000000000f050e005a590fa12 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
I n= ever liked call by reference. When I was trying to understand a chunk of co= de, it was a great mental=C2=A0simplification to know that whatever a calle= d routine did, it couldn't have an effect on the code I was trying to u= nderstand except through a returned=C2=A0value and (ghastly) global variabl= es. Operator=C2=A0overloading is far worse. Now I can't even be sure co= de I'm looking at is doing what I thought it did.

On Wed, May 13, = 2020 at 7:38 PM Dave Horsfall <dave= @horsfall.org> wrote:
On Tue, 12 May 2020, Paul Winalski wrote:

> Absolutely.=C2=A0 The projects that I ran effectively used C++ as a > stronger-typed version of C.=C2=A0 A small subset of C++ features were=
> allowed, but among the prohibited features were:

[...]

> o operator overloading

[...]

I never could figure out why Stroustrup implemented that "feature"= ;; let's
see, this operator usually means this, except when you use it in that
situation in which case it means something else.=C2=A0 Now, try debugging t= hat.

I had to learn C++ for a project at $WORK years ago (the client demanded it), and boy was I glad when I left...

-- Dave
--000000000000f050e005a590fa12--