Re: Blocks runtime in the kernel

From: Hans Petter Selasky <hps_at_selasky.org>
Date: Tue, 28 Mar 2023 19:01:20 UTC
On 3/28/23 21:43, Justin Hibbits wrote:
> On a side note, a friend of mine would love to see C++ in the kernel,
> but that's a discussion for another day.

Hi,

I've never used blocks before, but it kind of gets me thinking about C++ 
templates.

Can't you just use static inline functions, and the compiler will insert 
and optimise the code for you?

Or make some macros to generate foreach functions doing various simple 
things?

Personally, it took many years before I grasped all of C++ . I'm worried 
that blocks is one of those features that look nice, but have strange 
corners and require more from code analysis. For example if you do 
static code analysis and use blocks, will the static code analysis tool 
be completely lost? What about services like coverty? Do they find bugs 
hidden when using blocks?

--HPS