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.0 required=5.0 tests=MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 5485 invoked from network); 7 Jun 2020 22:57:24 -0000 Received: from minnie.tuhs.org (45.79.103.53) by inbox.vuxu.org with ESMTPUTF8; 7 Jun 2020 22:57:24 -0000 Received: by minnie.tuhs.org (Postfix, from userid 112) id E67CB9CA44; Mon, 8 Jun 2020 08:57:20 +1000 (AEST) Received: from minnie.tuhs.org (localhost [127.0.0.1]) by minnie.tuhs.org (Postfix) with ESMTP id 8F55D9C5F8; Mon, 8 Jun 2020 08:56:54 +1000 (AEST) Received: by minnie.tuhs.org (Postfix, from userid 112) id B218E9C5F8; Mon, 8 Jun 2020 08:56:51 +1000 (AEST) Received: from elf.torek.net (unknown [96.78.171.221]) by minnie.tuhs.org (Postfix) with ESMTPS id 531BF9C5E5 for ; Mon, 8 Jun 2020 08:56:51 +1000 (AEST) Received: from elf.torek.net (localhost [127.0.0.1]) by elf.torek.net (8.15.2/8.15.2) with ESMTP id 057Muo1h090326 for ; Sun, 7 Jun 2020 15:56:50 -0700 (PDT) (envelope-from torek@torek.net) Message-Id: <202006072256.057Muo1h090326@elf.torek.net> From: Chris Torek To: TUHS main list In-reply-to: Your message of "Sun, 07 Jun 2020 18:16:36 -0400." MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <90324.1591570605.1@elf.torek.net> Date: Sun, 07 Jun 2020 15:56:45 -0700 X-Greylist: inspected by milter-greylist-4.6.2 (elf.torek.net [127.0.0.1]); Sun, 07 Jun 2020 15:56:50 -0700 (PDT) for IP:'127.0.0.1' DOMAIN:'localhost' HELO:'elf.torek.net' FROM:'torek@torek.net' RCPT:'' X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.6.2 (elf.torek.net [127.0.0.1]); Sun, 07 Jun 2020 15:56:50 -0700 (PDT) Subject: Re: [TUHS] History of popularity of 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" >Safe Rust code is data race free, but not free of race >conditions, let alone thread safe in all ways. Er, yes. I mainly wanted to contrast to Go, where you look for race conditions by building with a flag that enables runtime checking. This can only detect races that actually occur, and if there are paths that would still have races that didn't occur on your test run, well... >>[rust array limitations] >I'm afraid this is incorrect. Rust arrays are indexed by a >`usize`, which is basically whatever `size_t` would be in C. Rust >arrays in general can be essentially arbitrarily large (up to >limitations imposed by the target machine, of course). >However, Rust does not support dependent types, most certainly >not for arrays. In other words, an array's size is considered >part of its type and so when specializing traits on arrays, one >must do so explicitly for each supported array size. For >practical reasons such implementations are often limited to a >relatively small number of distinct sizes; 32 is a believable >number. Perhaps that's what you're thinking of? Ah, yes, that was it. (As I said, I never really had time to do anything "real" in Rust.) Go's slices are nice to use, but slices (and maps, for that matter) trip people up because they are headers that point to shared spaces. Chris