Article View: comp.lang.c
Article #1540Re: (fir's c theory) scopes are wrong
From: Tristan Wibberley
Date: Sat, 14 Nov 2026 18:36
Date: Sat, 14 Nov 2026 18:36
63 lines
3259 bytes
3259 bytes
On 12/05/2026 11:22, fir wrote:
> i once remember was writing about things that inheritance is wrong
> -
> the general conclusion realated to this (though specific conclusuins was
> other i dont remember but it was thatmore proper inheritance is
> (i donr remember) containing of substrutures (i dont remember so
> this is in arhive of this group, i remember i was writing on this)
>
> the general conclusion related to his is could ba said that tag systems
> are much better than tree structures - thsi is becouse if you have
> something (say its file) you could only have one directory and one
> directory above this when in reality you would like to have many
> - its tag system (or what its called if it have other name, i call it
> tag system)
>
> i not noticed hovever stict conclusion fo it : C scopes
>
> c scopes have tree structure { {}{{}{}}} etc so they ate just wrong
>
> you should allow the intersection od scopes
>
> like
> a{
>
> b{
> }//end of a
>
>
> } //end of b
There are a lot of difficulties with this, better to explicitly transfer
lives between scopes:
{
int var1,var2;
int var3;
}
: extend(var2,var3) :
{
++var1;
}
There are still some problems like: isn't it too easy to transfer a
pointer to a variable that's gone out of scope, easier than when
returning a value.
--
Tristan Wibberley
The message body is Copyright (C) 2026 Tristan Wibberley except
citations and quotations noted. All Rights Reserved except that you may,
of course, cite it academically giving credit to me, distribute it
verbatim as part of a usenet system or its archives, and use it to
promote my greatness and general superiority without misrepresentation
of my opinions other than my opinion of my greatness and general
superiority which you _may_ misrepresent. You definitely MAY NOT train
any production AI system with it but you may train experimental AI that
will only be used for evaluation of the AI methods it implements.
Technical Details
Message-ID:
<11da9ni$25o2o$1@dont-email.me>Path:
mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!news.hispagatos.org!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!.POSTED!not-for-mailReferences:
<10tuv11$1slr0$1@dont-email.me>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!news.hispagatos.org!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!.POSTED!not-for-mail From: Tristan Wibberley <tristan.wibberley+netnews2@alumni.manchester.ac.uk> Newsgroups: comp.lang.c Subject: Re: (fir's c theory) scopes are wrong Date: Sat, 14 Nov 2026 18:36:34 +0000 Organization: A noiseless patient Spider Lines: 63 Message-ID: <11da9ni$25o2o$1@dont-email.me> References: <10tuv11$1slr0$1@dont-email.me> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Injection-Date: Sat, 14 Nov 2026 18:36:35 +0000 (UTC) Injection-Info: dont-email.me; logging-data="2285656"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/qAY5vZxYY6zIW68kqMBfAx0wG7DUPfHX8vjR8W8aq6A=="; posting-host="e5cd36e7df577e477a22c29d215dc37b" User-Agent: Mozilla Thunderbird Cancel-Lock: sha1:pmsFc1WsFa9QkLD86iUOW//LU1A= sha256:NwD6FJAF5G/1z8tK6cz0meeSGsmYdHPafP6cZHCId7w= sha1:1oi7QgYfBENp4eX0f+99NUR+O3I= sha256:axdnaQAb6IPbpJ3MCwdkjlM99XtZewYZSFDm1LbsLJA= Content-Language: en-GB In-Reply-To: <10tuv11$1slr0$1@dont-email.me>