From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) 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.2 Received: (qmail 841 invoked from network); 25 Apr 2020 21:35:06 -0000 Received: from minnie.tuhs.org (45.79.103.53) by inbox.vuxu.org with UTF8ESMTPZ; 25 Apr 2020 21:35:06 -0000 Received: by minnie.tuhs.org (Postfix, from userid 112) id 753FD9C921; Sun, 26 Apr 2020 07:35:05 +1000 (AEST) Received: from minnie.tuhs.org (localhost [127.0.0.1]) by minnie.tuhs.org (Postfix) with ESMTP id F04B99C733; Sun, 26 Apr 2020 07:34:50 +1000 (AEST) Authentication-Results: minnie.tuhs.org; dkim=pass (2048-bit key; unprotected) header.d=bellsouth.net header.i=@bellsouth.net header.b="RE/ksFRO"; dkim-atps=neutral Received: by minnie.tuhs.org (Postfix, from userid 112) id 30ACD9C733; Sun, 26 Apr 2020 07:34:49 +1000 (AEST) Received: from sonic315-19.consmr.mail.bf2.yahoo.com (sonic315-19.consmr.mail.bf2.yahoo.com [74.6.134.193]) by minnie.tuhs.org (Postfix) with ESMTPS id C672F9B962 for ; Sun, 26 Apr 2020 07:34:48 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bellsouth.net; s=s2048; t=1587850488; bh=bMh/tO+CuqD17IRt2WGmceMWlI6EQ7ywVJ8bB3Djg+A=; h=Date:From:To:In-Reply-To:References:Subject:From:Subject; b=RE/ksFRO/2mrqugkqTe46soaBBgD7Y0hLdfd3HQSQ3iM+n0lG7fUxOapaMBfiP7UDR8DFGNkLwWJ6ddn6RxnlohAIvxG2ERnNuhw4X8jwa+zSOD5lwA9XMD3nQw3mSMhfQGF1PmNRFjS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L14YaE72Ve4oHuTcu_M3S4kLVwvR9QFEcp3Eys_azoZx4YT1 NyFbsVfGKpPReMqlGGnLcfHkoBjuG4h2aSvDCUiyuGCJkTEMGGnVerEBmTB1VbYOFCfvqf0Ii0Jr xxXnFlvp0IvLsS_9iZY3ZFHnsixMdI7YsGYYR4UP81gAvYZbzRUzUKMrqesPDuq3yXu17V91AjHo DsMdCyGxYyn5xi2fSNALHSR1D7rSCywyZvftKC1dlqJ2VJ6I3JkcLfsWVmTCp7qPlNCYHabm2_yp m.BLqUmPtXf6.y32zdasnjernmPkZGIEu6gCkKOnOyjEAW3SyHUHHyAEZ8v3g5r87lVrSCUviRQZ h69.yQ9sHk69.1IJTdxE3WdZEJTqie0e5cqDVIlkTsvfO4nEufu3crNxfP.uTk.vi8ZQuUHJFoHR HP_NytUv.pVzuBP5_fG.4SKDcmtfQEYfyUOU4FvHaS2rsJX9U.TfR_HaPGrk9JlA0cR4ZuA37WWa Dfw-- Received: from sonic.gate.mail.ne1.yahoo.com by sonic315.consmr.mail.bf2.yahoo.com with HTTP; Sat, 25 Apr 2020 21:34:48 +0000 Date: Sat, 25 Apr 2020 21:34:44 +0000 (UTC) From: "Brian L. Stuart" To: tuhs@minnie.tuhs.org, =?UTF-8?Q?Michael_Kj=C3=B6rling?= Message-ID: <1862444098.192050.1587850484006@mail.yahoo.com> In-Reply-To: <9900c104-6f80-4b35-ae53-08b95c9dfbdf@localhost> References: <20200425131112.6E54F18C0B6@mercury.lcs.mit.edu> <1587821712.2206.338.camel@mni.thm.de> <2050076633.160857.1587841270567@mail.yahoo.com> <9900c104-6f80-4b35-ae53-08b95c9dfbdf@localhost> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_192049_914382820.1587850484005" X-Mailer: WebService/1.1.15756 YMailNodin Mozilla/5.0 (X11; FreeBSD amd64; rv:75.0) Gecko/20100101 Firefox/75.0 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: , Errors-To: tuhs-bounces@minnie.tuhs.org Sender: "TUHS" ------=_Part_192049_914382820.1587850484005 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On Saturday, April 25, 2020, 04:17:14 PM EDT, Michael Kj=C3=B6rling wrote: > I was thinking: couldn't we apply the same kind of reasoning to > variables as well? > ... In short, yes. In the language Bliss, all identifiers stood for the address of that thing. A prefix dot (.) dereferences that thing. So copying x to y would be something like y =3D .x; In C, rvalues have an implicit dereference happening. I've actually created a toy language that I subject my students to that revives the Bliss view to drive home in their minds the difference between the address of a memory location and the contents of a memory location. I want them to have some concept of how the program connects to the machine before they find themselves so mired in abstraction that everything is treated as magic. One of my TAs in that class last fall was taking a class in the winter where she was using C seriously for the first time and having trouble understanding pointers. When I explained how C pointers worked in terms of the variables and dots of this other language it became much more clear for her. BLS =20 ------=_Part_192049_914382820.1587850484005 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
On Saturday, April 25, 2020, 04:17:14 PM EDT, Michael = Kj=C3=B6rling <michael@kjorling.se> wrote:
> I was thinking: co= uldn't we apply the same kind of reasoning to
> variables as well= ?
> ...

In short, yes. In the language Bliss, all identifiers=
stood for the address of that thing. A prefix dot (.)
dereferences = that thing. So copying x to y would be
something like

y =3D .x;<= br>
In C, rvalues have an implicit dereference happening.

I'v= e actually created a toy language that I subject
my students to that rev= ives the Bliss view to drive
home in their minds the difference between = the
address of a memory location and the contents
of a memory locatio= n. I want them to have some
concept of how the program connects to the = machine
before they find themselves so mired in abstraction
that ever= ything is treated as magic.

One of my TAs in that class last fall wa= s taking a
class in the winter where she was using C seriously
for th= e first time and having trouble understanding
pointers. When I explained= how C pointers worked
in terms of the variables and dots of this other<= br>language it became much more clear for her.

BLS
=20 ------=_Part_192049_914382820.1587850484005--