🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.c
Article #1953

Re: C and its peasant 'ancestors'

#1953
From: David Brown
Date: Sat, 28 Nov 2026 21:59
72 lines
5033 bytes
On 28/11/2026 21:15, Michael S wrote:
> On Sat, 28 Nov 2026 20:34:10 +0100
> David Brown <david.brown@hesbynett.no> wrote:
> 
>> On 28/11/2026 19:47, Scott Lurndal wrote:
>>> Lawrence =?iso-8859-13?q?D=FFOliveiro?= <ldo@nz.invalid> writes:
>>>> On Thu, 26 Nov 2026 12:48:26 +0100, Bonita Montero wrote:
>>>>   
>>>>> Am 26.11.2026 um 12:36 schrieb fir:
>>>>>   
>>>>>> 1. the bloat of terrible c++ syntax (oop and those generix and
>>>>>> those all other non sane additions)
>>>>>
>>>>> It’s only "bloat" if you aren’t up to the task of handling it. I
>>>>> actually find C to be much more bloated, because the things you
>>>>> end up having to do alongside C++ often require a significant
>>>>> amount of real work.
>>>>
>>>> Would you like to take the Linus Torvalds challenge? He famously
>>>> hates C++, and won’t allow it into the Linux kernel.
>>>
>>> I've worked on a full scale, massively parallel operating
>>> system and a distributed virtual machine manager, both written
>>> in C++ very successfully.
>>>
>>> Of course, one must carefully choose _which_ C++ features
>>> are used (limited use of templates, no exceptions, no RTTI
>>> very limited STL (which didn't exist when the OS project
>>> started in 1989) for optimal performance.
>>>
>>> C with classes isn't a bad description - one receives all the
>>> benefits of data hiding and inheritance provided by the class
>>> paradigm without the overhead required for stack unwinding and
>>> dynamic_cast<>.
>>
>> There's a /lot/ more than just "C with classes" that is appropriate
>> for low-level, bare metal and/or embedded programming in C++.  It is
>> typically more a matter of what you want to avoid - dynamic memory,
>> virtual functions (usually), exceptions, and anything else that has
>> unexpected or unpredictable runtime costs.  I use a large number of
>> C++ features in my small-systems embedded programming, but you do
>> have to know what to avoid.  (I also avoid malloc/free and a number
>> of other features and functions of C in embedded programming, but it
>> is more obvious which should be avoided.)
>>
>> To be fair, the C++ language and toolchains are far better suited to
>> embedded programming than they were in 1989 !
>>
>> (And they are getting better - there is progress being made
>> specifically towards more features suitable for freestanding systems,
>> such as inplace_vector.)
>>
> 
> Try C in your next project.
> You will be pleasantly surprised by productivity gain from using
> simpler language. May be, less so during initial coding, more so during
> later maintenance.
> 

I work with both C and C++ projects.  When starting a new project, /I/ 
make the choice of language.  You make it sound like moving to C would 
be something new for me.  I moved to C++ from C as my usual choice 
precisely because it lets me write better code with fewer bugs, with 
similar or better efficiency.  To me, it is a clear step above C in most 
projects - just as C is a clear step above the assembly I used to use.

Of course, I have to use C++ appropriately for the task in hand - not 
like Bonita's junk code.

And I will still use C if there is good reason for it (there can be a 
number of good reasons for sticking to C).
Technical Details
Message-ID: <11efirn$2v6lt$1@dont-email.me>
Path: mbox-mo1.pugleaf.net!srv.newsdeef.eu!news.hispagatos.org!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!.POSTED!not-for-mail
References: <11dup6q$v4j9$1@dont-email.me> <11e8stp$hajr$1@dont-email.me> <11e8ti0$hhqa$1@dont-email.me> <11e8v24$i2mc$2@raubtier-asyl.eternal-september.org> <11e9045$ihk3$1@dont-email.me> <11e90a8$ikh0$1@dont-email.me> <11e90mv$io87$2@raubtier-asyl.eternal-september.org> <11e91ns$j5dv$1@dont-email.me> <11e92ff$jclo$1@raubtier-asyl.eternal-september.org> <11e95j2$kimu$1@dont-email.me> <11e96aa$kpta$1@raubtier-asyl.eternal-september.org> <11ect54$20qpr$3@dont-email.me> <klFOS.164599$ZAo7.102690@fx18.iad> <11efabi$2rvk1$2@dont-email.me> <20261128221534.0000235d@yahoo.com>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!srv.newsdeef.eu!news.hispagatos.org!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!.POSTED!not-for-mail
From: David Brown <david.brown@hesbynett.no>
Newsgroups: comp.lang.c
Subject: Re: C and its peasant 'ancestors'
Date: Sat, 28 Nov 2026 22:59:19 +0100
Organization: A noiseless patient Spider
Lines: 72
Message-ID: <11efirn$2v6lt$1@dont-email.me>
References: <11dup6q$v4j9$1@dont-email.me> <11e8stp$hajr$1@dont-email.me>
 <11e8ti0$hhqa$1@dont-email.me>
 <11e8v24$i2mc$2@raubtier-asyl.eternal-september.org>
 <11e9045$ihk3$1@dont-email.me> <11e90a8$ikh0$1@dont-email.me>
 <11e90mv$io87$2@raubtier-asyl.eternal-september.org>
 <11e91ns$j5dv$1@dont-email.me>
 <11e92ff$jclo$1@raubtier-asyl.eternal-september.org>
 <11e95j2$kimu$1@dont-email.me>
 <11e96aa$kpta$1@raubtier-asyl.eternal-september.org>
 <11ect54$20qpr$3@dont-email.me> <klFOS.164599$ZAo7.102690@fx18.iad>
 <11efabi$2rvk1$2@dont-email.me> <20261128221534.0000235d@yahoo.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 28 Nov 2026 21:59:20 +0000 (UTC)
Injection-Info: dont-email.me;
	logging-data="3119805"; mail-complaints-to="abuse@eternal-september.org";	posting-account="U2FsdGVkX1+AOC3MfHasNEpEAR6xs2/UsJumKvhhu4U="; posting-host="830fabbfeda36f3c3fabbdfcbd22e3d2"
User-Agent: Mozilla Thunderbird
Cancel-Lock: sha1:0u5UVzw0oPZ1vHOyRa85ChqRiRI= sha256:r4sRId377WM8s66oYLRSxL238nBOi1wndnq+69OV7/E=
	sha1:4lWqHzLtVRPOeOqGZxEIXgiTKBY= sha256:BxTb8a1WRwlhojY7ap+E59Ujh3Os9li/MACXcxpUAPA=
Content-Language: en-GB
In-Reply-To: <20261128221534.0000235d@yahoo.com>