Deutsch   English   Français   Italiano  
<uv5gfd$qum1$1@dont-email.me>

View for Bookmarking (what is this?)
Look up another Usenet article

Path: ...!3.eu.feeder.erje.net!feeder.erje.net!weretis.net!feeder8.news.weretis.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: Lawrence D'Oliveiro <ldo@nz.invalid>
Newsgroups: comp.lang.c
Subject: Re: Recursion, Yo
Date: Wed, 10 Apr 2024 07:52:13 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 15
Message-ID: <uv5gfd$qum1$1@dont-email.me>
References: <uut24f$2icpb$1@dont-email.me> <uutqd2$bhl0$1@i2pn2.org>
	<uv2u2a$41j5$1@dont-email.me> <87edbestmg.fsf@bsb.me.uk>
	<uv4r9e$mdd3$1@dont-email.me> <uv5e3l$q885$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Wed, 10 Apr 2024 07:52:13 +0200 (CEST)
Injection-Info: dont-email.me; posting-host="7ce03bb5457ab82bf7e463e8fecedba8";
	logging-data="883393"; mail-complaints-to="abuse@eternal-september.org";	posting-account="U2FsdGVkX1/vXy2eLM0xd/RFAmfCqcbs"
User-Agent: Pan/0.155 (Kherson; fc5a80b8)
Cancel-Lock: sha1:oMnUf76G54o6qrBCTFSOF+yE9yE=
Bytes: 1839

On Wed, 10 Apr 2024 09:11:49 +0200, David Brown wrote:

> It is not much used in practice, AFAIK.  For some cases the code
> generation for nested functions was fine and straight-forward.  In other
> cases, however, it required a trampoline generated on the stack, and
> that became a real pain once non-executable stacks came into fashion.

That would be true of those other languages that require the feature, too.

> Nested functions were never as interesting for C++ as you already have
> better mechanisms for controlling scope and data access - classes and
> their methods, including nested classes.

Python does both. Just because you have classes doesn’t mean functions 
can’t be first-class objects, too.