Path: csiph.com!usenet.blueworldhosting.com!feeder01.blueworldhosting.com!border2.nntp.dca1.giganews.com!nntp.giganews.com!news.iecc.com!.POSTED.news.iecc.com!nerds-end From: George Neuner Newsgroups: comp.compilers Subject: Re: dead code or otherwise, was Alternative C compilers on x86_64 Linux? Date: Fri, 09 Sep 2016 14:02:16 -0400 Organization: A noiseless patient Spider Lines: 27 Sender: news@iecc.com Approved: comp.compilers@iecc.com Message-ID: <16-09-021@comp.compilers> References: <16-09-001@comp.compilers> <16-09-005@comp.compilers> <16-09-009@comp.compilers> <16-09-012@comp.compilers> <16-09-015@comp.compilers> <16-09-016@comp.compilers> <16-09-017@comp.compilers> <16-09-018@comp.compilers> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit Injection-Info: miucha.iecc.com; posting-host="news.iecc.com:2001:470:1f07:1126:0:676f:7373:6970"; logging-data="71793"; mail-complaints-to="abuse@iecc.com" Keywords: C, Lisp, comment Posted-Date: 09 Sep 2016 14:53:23 EDT X-submission-address: compilers@iecc.com X-moderator-address: compilers-request@iecc.com X-FAQ-and-archives: http://compilers.iecc.com Xref: csiph.com comp.compilers:1760 On Fri, 9 Sep 2016 06:05:44 +0000 (UTC), Kaz Kylheku <221-501-9011@kylheku.com> wrote: >On 2016-09-09, George Neuner wrote: >> But like any good Usenet discussion, it (d)evolved into something more >> general. >> >> Not every language with a CASE like construct has C's limitations on >> specifying the alternatives. Lisp certainly doesn't. > >Yes, it does, in fact. The labels in Lisp case are literals that are >embedded in the CASE syntax itself, and not evaluated. They are >compared to the input value using EQL equality. Duplicate cases >are a bug, which is not required to be diagnosed. Lisp does not restrict CASE "labels" to integers like C. They can be any of [at least] symbols, characters, integers or booleans. And unlike C where booleans and characters are subsets of integer, in Lisp they are discrete types. Additionally symbols are a reference type - a pointer to a structure. So no! Lisp does not have C's limitations. George [Lisp does restrict case labels to literals, so if two of them are the same, that's a bug. -John]