News for hackers. Stuff that matters.
Re:The Linux Kernel Looks to "Bite the Bullet" in Enabling M... by wahern on Monday November 10, 2025 @04:55AM (#45874338)
The original proposal at https://www.open-std.org/jtc1/sc22/wg14/www/docs/n1406.pdf explains why.

> Some implementations have permitted anonymous member-structures and -unions in extended C to contain tags, which allows tricks such as the following.

  struct point { float x, y, z; };
  struct location {
    char *name;
    struct point; // inheritance in extended C, but
                  // forward declaration in C++
  };
> This proposal does not support that practice, for two reasons. First, it introduces a gratuitous difference between C and C++, since C++ implementations must treat the declaration of point within location as a forward reference to the type location::point rather than a definition of an unnamed member. Second, this feature does not seem to be used widely in applications, perhaps because it compiles differently in extended C vs. C++.
Re:The Linux Kernel Looks to "Bite the Bullet" in Enabling M... by avadodin on Monday November 10, 2025 @04:33PM (#45881238)
If C and C++ standardization had included both languages since the beginning, compatibility could have been a thing but it didn't so the languages have diverged since C-with-classes.

I don't understand why the C standard has to get bogged down with bizarro-world-C restrictions from C++.

It's 2025, people have to give up on C/C++.

Re:The Linux Kernel Looks to "Bite the Bullet" in Enabling M... by IsTom on Tuesday November 11, 2025 @03:32AM (#45885252)
C++ routinely includes C headers and this would affect that. I think most things valid in C, but not C++ don't affect declarations.
Re:The Linux Kernel Looks to "Bite the Bullet" in Enabling M... by johnisgood on Tuesday November 11, 2025 @05:22AM (#45885827)
> It's 2025, people have to give up on C/C++.

No, people should not give up on C.

???

You do realize there are a lot of projects written in C, right? Including Linux and most of its programs / utilities that you may be using.

I have new projects written in C, too, and you can do a lot to check for potential bugs using various flags to GCC / Clang, among other things like cppcheck and the rest.

No, people should not give up on C. C is really good to know, for many reasons... even if you are not going to use it.

Re:The Linux Kernel Looks to "Bite the Bullet" in Enabling M... by bmacho on Tuesday November 11, 2025 @11:06AM (#45888919)
I believe GP meant that the idea of C/C++ should be abandoned, that is, that C and C++ are compatible languages. GP thinks that they should diverge more when necessary, none of them should be held back for the compatibility with the other.
Re:The Linux Kernel Looks to "Bite the Bullet" in Enabling M... by johnisgood on Tuesday November 11, 2025 @01:06PM (#45890714)
Well, I agree with that.