C cripples your mind.
You are a pedophile.
>>108416075C doesn't just cripple your mind, it lobotomizes it, and then makes you proud of the scar
what is your alternative op?
language of the godsmaking scriptlets seethe is a bonus
>>108416075I like it...how has it crippled me? also, wrong logo! picrel is the only true logo!
>>108416179The language you use shapes the thoughts you can think. If your language can't express a concept cleanly you tend to stop reaching for that concept. It's basically Sapir-Whorf for programming.C trains you to think in:- manual memory management- flat data structures- side effects everywhere- the machine's perspective, not the problem's perspective- hurrr durrr my machine is a PDP-11
>>108416319>the machine's perspective, not the problem's perspectivei hope that my program looks at the problem from the machines perspective. math fags btfo'd
>>108416319> side effects everywhereThat's on you.> flat data structureshuh?> Machine's perspective ...Yes, problems needs to be adapted to fit constraints imposed by the machine, C forces you to face said constraints. That is not a weakness, you're given all the tools to model the problems via abstractions that you invent. On a side note, this is what mathematics is all about. If you can't invent said abstractions and work around them via some higher level means it's fine. But you must come to terms with the fact that your solution might not be the most effective against said problem.
>>108416075You'll ask these people what you should be using instead, and they'll come up with the most disgraziato pigshit you've never wanted to see in your life.Which one is it OP? Pascal? Rust? Lay it on me.
>>108416405>Which one is it OP?ACTS + linear types for resource management.
>>108416395Well yeah, in that case C only makes sense if your machine is a PDP-11
>>108416462>>108416319>PDP-11 propagandaI'm so tired of this dumbass talking point. We get it, you read the headline of a paper when it was posted on Hacker News, and didn't spend 3 seconds thinking critically about it.
>>108416075You drive a car? Because guess what buddy, all those modules are written in C.
>>108416319>- manual memory managementC29's defer will alleviate this for the general case, but bump allocators pretty much solve this problem already.>- flat data structureshuh? what's this supposed to mean>- side effects everywherethe degree depends on how you program, you can pretty much leave out any global state, that'll get you quite far.but yes, C is a fundamentally imperative language. but that works quite well, because computers are also very much imperative machines.>- the machine's perspective, not the problem's perspectivethe only sensible domains for C these days are embedded and OS, where the machine domain is very much part of the problem domain.high performance libraries written in C also work well, but there it too is used for its close machine interop>- hurrr durrr my machine is a PDP-11yeah, for the most part it is. you're not particularly knowledgeable about computers by having read that one almost tabloid whitepaper>>108416482yeah, it's tiring. and so devilishly effective, too, because it's so easy to feel really smart parroting that paper's talking points.>>108416613that argument doesn't really make sense>You've interacted with a bank? Because guess what buddy, all those modules are written in COBOL!!but doesn't mean you should be using COBOL.
>>108416482Fuck no. It took the committee 50 years to add safe integer operations to the standard. I guess that in another 50 years or so, we might finally get support for multiprecision arithmetic (carry operations), since it's already supported on all modern hardware.
>>108416613Yeah, well, the car industry kinda sucks, they collectively chose Qt as the de facto framework for the industry, which is an indication of how bad things are. I wouldn't be surprised if they use C.
>>108416660C has served me well since the 90s. But then again I only do embedded systems work. There hasn't even been a single case where any other language even remotely posed any threat to it.You can seethe all you want, but C will be around for a long time. Might want to work on the coping phase next.
>>108416816next time maybe don't embarrass yourself by1. missing the point2. ignoring the point and arguing against some spectre3. proving yourself incapable of taking in contextgood luck!
>>108416660>C29's defer will alleviate this for the general case, but bump allocators pretty much solve this problem already.The problem is that you're thinking of a palliative solution instead of a radical one. Radical solutions mean having a proper way to enforce memory deallocation, and for that, you need a language other than C. Programmers will always make mistakes.>but yes, C is a fundamentally imperative language. but that works quite well, because computers are also very much imperative machines.An effect system will not change the imperative nature of any language.>the only sensible domains for C these days are embedded and OS, where the machine domain is very much part of the problem domain.That is bullshit, it’s a poor excuse for a lack of high-level abstractions. A good language would allow you to write very low-level code when needed, as well as extremely high-level code.
>>108416794>multiprecision arithmetic (carry operations), since it's already supported on all modern hardware.Not on RISC-V, so probably not.
>>108416863I see you've chosen to keep seething. Well hopefully you can work through it one day.
>>108416884>palliative, Radical solutionsyeah, I'm very much holding out for a language that uses a borrowing system somewhat like Rust but without all the cruft that Rust brings along, too. It's just too try-hard multi-paradigm for my liking. (just like C++!! who would've thought!)>effect systemah, okay. I'd thought that you were alluding to stateless(ie. functional) languages.I have not really interacted with effect systems much, the only thing I know about them (apart from all the capability stuff) is their supposed reversibility, and I've only seen them used in functional languages.I don't see how you can reasonably implement that in an imperative context given *all* the ways state can be altered when you mix indirection through pointers + opaque types + binary blob libraries etc. Have there been some findings that one should take a look at?>lack of high-level abstractionsno, I fundamentally disagree. I just simply do not enjoy writing highly-abstracted code, and I have seen fairly few convincing arguments in their favour. Yes, once you've come across an algorithm it is very satisfying to be able to write it out almost as if it were maths, but I've found it much more practical to write out the simple imperative step-by-step algorithm. It's more easily understood, it is more readily editable and quite frequently manages to be more efficient, too.Has your experience been different?>>108416947No anon, you've misunderstood again. I'm simply somewhat disappointed that instead of the nice discussion that could've been had, you instead chose to unnecessarily reply inflammatorily.Which in principle, fair enough, we're on 4chan(nel). but at the very least interact with the actual content of the post, otherwise it just comes of as desperate and more than a little pathetic.
>>108416151I am not OP, but you know... the fucking obvious:RustZigNimC just seems incomplete to me. Like some relic of the past with incomplete toolset, syntax, build system... like some shit parents of boomers used on green screen computers.I don't get the flex about "Managing your memory yourself". You aren't, you are introducing bugs and just don't know about them because it hasn't hit your use case yet. Rust eliminates that at language design level. You're not better than static analysis, you're just deluded.So when someone flexes this to me I immediately know I am talking to a fucking idiot, and politely move that person to idiot reg in my mind. Forever.
>>108417040>It's just too try-hard multi-paradigm for my likingNot being able to wrap your mind around functional paradigm of programming is something I've noticed with a lot of c-niles.Its like kryptonite to them. You guys should learn OCaml just to make sure you still can learn anything at all.
>>108416319>- the machine's perspective, not the problem's perspectiveyour problem still needs to have the solution computed on a machine. you better understand wtf it's doing or your code will be slow as shit
>>108416398>abstractions that you invent.C is maybe the most abstraction unfriendly language in existence. It was not designed with abstractions in mind, because at the time of its design the problems didn't require any significant abstractions.Go design a distributed actor framework in C. You can. You can also paint a wall with a toothbrush.
>>108417211What made you think actors were a metric?
>>108417134>implying fp is difficultI've seen people break trying to learn VHDL and Verilog, they can't handle the parallelism. FP is a fucking joke in comparison. You know what the truth is, everyone who hates C doesn't do embedded systems. It's really that simple. You can hate it all you want outside that scope, but when it comes to firmware and hardware all the arguments are obliterated.
>>108417218Designing my own in C# because I didn't want to rely on AKKA.NET. It was a surprisingly complex minefield. High level nature of .net made it easier, and it would have been a lot less so in C.>>108417236> C only makes sense in embeddedI agree. Even then I'd still try going minimal rust way.
>>108417267Rust isn't a C replacement, it's more for C++, and guess what, we don't use C++ in embedded. If I were hiring someone for an embedded position and saw C++ or rust on their resume, into the trash it goes.
>>108417291>it's more for C++Its more C + OCaml>we don't use C++ in embeddedYou're building a strawman here.>If I were hiring someone for an embedded position and saw C++ or rust on their resume, into the trash it goes.You won't be hiring them. Someone else will be. And they will deliver better product with more features and less bugs.This exists you know: https://docs.rust-embedded.org/book/
>>108416075>no built in data structures (no, your amateur hashmap implementation is not going to be better than a group of experts)>no generics (good luck getting anything done)>null terminated strings>zero null safety>unions are not tagged (useless)>enums are not typesafe>no modules or namespaces>header file bullshitwho came up with this dogshit language lol
>>108417348Determinism always wins in embedded. C let's you build up to it, everything else requires you try to build down to it. C gets you the optimal system requirements faster, without any bugs, and with 100% deterministic solution. You start from a point of using bloated abstracted languages, your system is going to full of bloat, bugs, and failure points.If you need a higher level language for GUI, you build a separate system and interface it. I think that's the real problem here, most people look for a language to handle both the system design and the GUI because they're low IQ. High IQ is realizing they are different problems and can and should be separated.
I know C, I've learned how to program with C, a long time agobut how do I git gud?asking for a friend btw
>>108417405embedded is one of the most overrated fields inside programming. it's all just memory mapped IO. you feel like a genius for looking up magic memory addresses in the hardware manual and reading/writing to them in C. it's extremely simple. i would go as far to say that webshitter frontend frameworks are more complicated than that.
>>108417236>I've seen people break trying to learn VHDL and Verilog, they can't handle the parallelism. FP is a fucking joke in comparison.Bruh understanding shit working in parallell is easy as fuck. It is litterally just a circuit bifurcating into branches that update at the same time. The annoying shit about verilog is how cumbersome verifying digital circuits is compared to testing a software program. By far most digital circuit design qork hours are spent on verification.
>>108417134lmao, fp isn't difficult and nowhere did I imply that.>>108417291>and guess what, we don't use C++ in embeddedthat's not even true, though. C++ is already quite widespread in embedded>>108417405that's my problem with rust, too. it tries to be a language for embedded AND OS work AND game programming AND webdev AND...which just doesn't make sense to me. use different languages for those
>>108417442don't topple his house of cards like that... he's built his entire identity about being muh epic low-level C programmer, he really can't handle it
>>108417442You do realize you need to understand the circuits right? My background is as an EE, but I also have a CS, which was 100% in C.>>108417445It's easy for some people who are inclined to systems thinking, most people aren't. I hear you though about HDLs, writing testbenches was always the worst part of it.
>>108417451Incorrect. Some places use C++ in embedded. We never used it my field (automotive). That may have changed now, but I doubt it.
>>108417134>Not being able to wrap your mind around functional paradigm of programming is something I've noticed with a lot of c-niles.A lot of people that end up doing C at work come from EE/ECE backgrounds where super computer sciency shit like that is pretty much completely skipped. I still have no clue what functional programing is and never heard about it in college and I have a masters kek. All our course matter is about embedded, microcode, digital electronics, HW/SW codesign and shit like that, not regular software/cs shit.
>average pointer enjoyer
>>108417470>You do realize you need to understand the circuits right?depends on the kind of embedded you're doing. some baseline understanding of the circuits and being able to take measurements/ interpret them often suffices for the software part of embedded. I've very rarely had to actually design a circuit myself, we've most often just bought them from the market (especially in recent years with ongoing trend of integrating all embedded systems into one central hub)
>>108417487I have both EE and CS, honestly as long as you've gone through data structures in C that's about all you need for embedded firmware from the CS side. Of course as you know, that's the trivial part relative to everything else an EE has to know.
>>108417442>t. went through an embedded 101 college class and thinks that's all there isAnon please
>>108417507Are you the EE + CS anon? What else is there? I'm doing embedded in uni atm, but with a focus from the software side.
>>108417501I'm retired now, but I wouldn't be surprised by how things are going. From my perspective it was always about maximizing optimization. You use exactly the hardware you need for a problem because the production cost and waste otherwise adds up fast. It was towards the end when I saw the severe shift towards planned obsolescence. I refused and decided to nope out at that point. I grew up in a time you didn't waste anything in tech, right down to a bit.
>>108416075>C cripples your mind.Whatever, rust-troon.
>>108417539Tech is changing fast anon. I went through EE+CS in the mid to late 90s. I don't think I would have done either in this current world if I'm being honest, I just don't like the direction tech has taken on some deep level.
>>108417501When you are working on some part of a big system, usually you need to understand thibgs pretty well because there's lots of timings and things like that which need to be respected or the whole thing breaks.The whole thing with embedded is that you have to deal with strict rules and limited resources to implement solutions that have to pretty much be reliable 100% of the time (though this depends on what the system is, obviously. It is not the same coding a super complex SoC or the control system of a guided missile than coding a washing machine).
>>108416075>>108417101Don't care I just wanna have complete control over my code. I don't want a nanny telling me what I can and can't do. Just stick basically everything you can on the stack and write your own data structures to handle everything else, easy. Only gripes I really have is the retarded lack of a build system and header files. Introspection and lisp style macros would be nice too I guess.>>108417356>no built in data structures>no genericsSkill issue, try properly thinking through your code first.
>>108416075>C cripples your mind.>Muh C is bad>Please help, I cant codeTry HolyC if you don't like C you dickhead
>>108417487>I still have no clue what functional programming is and never heard about it in college and I have a masters kekThat's normal unfortunately. When I learned Haskell (don't bother, learn OCaml instead), it was like learning programming from scratch. But now its all kind of merged together into one picture for me. Imperative for low level, high level - all functional. Functional is far superior to imperative as far as abstractions go - which is why every high level language and framework has been integrating its concepts.>>108417648>Don't care I just wanna have complete control over my code.Rust unsafe gives you all that. And it has modules, and the best tooling of anything out there rn. Its your loss honestly. 100% worth every second i dumped into learning it, even though now its just all claude cli for me. I still read everything.
>>108417451>that's my problem with rust, too. it tries to be a language for embedded AND OS work AND game programming AND webdev AND...>which just doesn't make sense to me. use different languages for thoseAnd it succeeds at all of that. Spectacularly.You just don't know it, so you have no idea what its capable of.
C: dumb faggot trannyRust: smart faggot trannyC++: smart cis hetero
>>108417539As with pretty much everything even tangentially hardware related, the best way to learn the "real thing" is by far working on real projects with actual specs, constraints and a certain level of complexity. Drill the fudamentals, try to become hardware literate at least when it cones to understanding where your code would fit/how it would interact with different systems and try to get internships that geg you working on something as complex or performance critical as possible that seems interesting to you. You can also join some interesting club at your college if there's some working on good projects like drones, formula student, rocketry and things like that.The main obstacle when it comes to getting good at embedded is that you will have a lot of trouble getting good systems to practice on if you are not at an environment where hardware-focused people do most of the hardware job so the firmware focused people can focus on bringing it to life. In the world of hardware systems-related stuff there's only so much a dude can do in his bedroom alone.
>>108417880>In the world of hardware systems-related stuff there's only so much a dude can do in his bedroom aloneWhich is why, in most cases, embedded college classes end up feeling super barebones or railroaded.
>>108417751I'm quite well versed in Rust, thank you, the only part I have not done much with is trait objects.And no, Rust is ill-suited for plenty of domains, they bit off more than they could chew trying to make it work for everything.
>>108417776C++ just takes C and slaps random shit on it (that can admittedly be useful) and calls it good. Doesn't actually solve any of the pain points of C, just adds random features to it. Just use a language with an actual build system for one at that point, don't even bother with manually managing memory. Just admit you wanna be a lazy nigger and not have to bother actually writing code. Why bother even trying to write something elegant if you're just gonna use C++.
>>108417924You're looking at it the wrong way. Classes like microelectronics are only designed to teach you puzzle pieces. The way to learn engineering is to work backwards from the solution you need for a specific problem. You can work out the engineering in reduction and learn. Experience just shortens the time considerably, but you'll learn in the process.I mean at the end of the day, it's all problem-solution dynamics. You understand a problem sufficiently, you develop a solution that's feasible/reasonable, and you break it down as far as needed in reduction. Time consuming, but simple.
>>108417442>embedded is one of the most overrated fields inside programming. it's all just memory mapped IOand interrupts and DMA and real time OS and DSP and real time communications...
C not only forces you to learn more about computers, and the structure of your code, it makes programming fun.not to mention your code will be 100x faster than any high level slop
>>108417442That and wrangling the tools to minimize your binary size so you can fit in the retarded chip the retarded EE chose because "the pins are easier to design for" but it has a quarter the memory that your application needs.
>>108417648>Don't care I just wanna have complete control over my code.Pointer provenance would like to have a word with you.
People be like "omg C is le unsafe old language" and then you look at military, telecom and transportation software all over the world and it's all C under the MISRA, JSF or NASA/JPL rules, many times it's wrapped in Ada (which is also very old and kinda weird) but in general no one is using modern languages for low level systems that need safety guarantees.>Zig, Nim, Odin whatevermeme tier>GoToo focused on webshitt and has built in garbage collection >RustHas potential but the syntax and lack of a standard/stableABI/compatibility guarantees turn many people off >C++99% of the language is banned in these environments
Can any C old fags spoon feed me best practices for writing good C code? I'm learning about valgrind and how to use that, but honestly finding info about writing organized non memory leaky code is hard.
>>108419049you learn by doing projects, making mistakes, doing postmortems, and trying out different approaches on future projects. rinse and repeat.sometimes you'll read some really well designed code and pick up some ideas. but there is no central repository on how to git gud other than experience.
>>108416075>C cripples your mind.t. cripped by C
>>108419049malloc one at program start
>>108417648>complete control over my code.yeah like you're actually writing assembly and linker scripts by hand.
>>108419049that's because most of learning C is actually just managing lifecycles of your shit.use libasan
>>108416660god damn that defer syntax is nicei already handle most of it with attribute cleanup, but defer allows you to do per-function cleanup. this would basically allow me to remove a shitload of goto statements. godddd that would be so nice
>>108419373NTA but I do this at my job. It's actually pretty fun. I put a CRC algorithm in a vector table and use a common linker script to describe all the memory regions and stuff and export all those regions and symbols into the three executables I build for my target. The satisfaction of having such tight control over how everything plays out feels very good.
>>108417356>no built in data structurespositive>no genericseither nocoder or architecure astronaut meme https://en.wikipedia.org/wiki/Architecture_astronaut>null terminated stringsthe simplest way (otherwise tell which is the simplest way). also, theres no string but only a string literal (the trick doesnt fit retarded brain, huh?)https://www.youtube.com/watch?v=y8PLpDgZc0E>zero null safetywear diapers (You)>unions are not tagged (useless)who?>enums are not typesafewhat?>no modules or namespacesmodules are called units, there is "static" keyword. in actuality, C is the language to write modules (libraries, those DLL/SO dynamic/static files), others take them and rewrite them, but origins are traceable.>header file bullshitthen dont use them>who came up with this dogshit language lolsome programming mastermind>>108417776>smart cis heterowho is transitioning to Rust (fact)>>108417729> Rust>>108414248its not for humans addicted to programming, its for selling IDEs and automation systems. poor readability (matters).
>>108419613Most of what you've said is reasonable. C's lack of modules/namespaces makes it less usable. Having to manually prefix identifiers to prevent collisions is retarded. I should be able to `import as` a given TU and resolve accordingly. Everything else you've said is reasonable.
Yeah - what we actually need is a concatenative, capability-secure, monoidal systems language with indexed semantic constraints and reflection gated by authority.… until then - it might remain C …
>>108419637>Having to manually prefix identifiers to prevent collisions is retardedlittle difference string::thisOne(), Str\thisOne() or str_thisOne(). also,> there is "static" keywordand headers>>108419373> ...linker scripts by hand.you cannot avoid linker, otherwise you dont know what youre building: console app? window app? static library? dynamic library? etc. more abstraction on top of **simply passing args to the linker** obfuscates building and creates more jobs (deps), the whole zoo of them: perl, cmake, python, autotools, bash, sphinx, pkg-config, visual studio, who-knows-what-else. those tools make library build poorly separated from binary (tool) build, the codebase becomes bloated.
>>108416455>no existing implementationoh, so you don't program. opinion discarded
>>108419736On second thought I think you're right enough that it isn't worth arguing about.
>>108419613C zero terminated strings are miserable simply on a basis of not being recursively subreferencable and so many existing libraries just expect the termination instead of providing explicit length.I'm glad that in 2026 it's at least a norm to provide dual API with length or ssize_t where -1 means to call strlen and it's socialy acceptable to call a developers nigger faggots if they don't, but older stuff usually doesn't do it.Not coupling length with array pointers is just crippling any static analysis tools since you often have to annotate the code with attributes to enable it.If C had slices implemented as fat pointers and gave up on zero terminated strings, it would be infinitely better language.
I just like larping as a based kernel developer
>>108419736the only person i ever met that calls the linker "linker" (no article) was a chinese TA back in my ugrad daysit made me chuckle, i loved how he spoke
>>108416087could be worse, you could be a tranny programming with Rust
free(your_mind)
>>108416075>>108416080Cunny
>>108416319i didn't learn any of this when i learned c (or any of the programming languages) the teachers always said " the way tech is going, there's going to be a lot of memory, so you don't need to worry about that, here, learn C#"and didn't teach me anything valuable at all.
>>108416319anon, explain flat data structures
>>108417040>I'm very much holding out for a language that uses a borrowing system somewhat like Rust but without all the cruft that Rust brings along, too.Difficult to get the edge cases right without bringing a lot of extra horribleness along for the ride.The simplest method for the end programmer is actually garbage collection. You might not like it, but it's very easy to use.
>>108417971>C++ just takes C and slaps random shit on itThe biggest problem of C++ is that it has so much random shit bolted on, and none of the old stuff is gone either, so every piece of code using C++ is using a different subset of features. And lots of different things don't work together well in weird ways.It's the fucking Balkan Peninsula of programming languages.
>>108417101if you could reinvent the hammer, what would you do to it?what if you could reinvent the knife? sure, there are things that individually have their place, but the primitive design is kept because you can build with it and it works great. sure, you may find some newer designs that add extra useful things to it, (hammer with a magnetic nail holder, or a foldable grip on a knife) but in the end, the primitive form is the best form.this is what the nutrannycoders miss, their blinded by the sparkly things the new languages offer, that they miss the use (and skills) of the primitive languages. it's why you're all vibe coders and don't understand what your code is doing. how does a spear work? what if a bow? can you even make an arrow head out of flint?can you start a fire? can you actually understand what you're doing and apply that knowledge to create? are you a fire keeper? or do you actually hold the key to create fires? can you actually program? it does a machine so it for you?
>>108417356>I can only imagine doing one type of programming in one way, so everyone else must also be doing that.Midwit. Why not stick to Haskell?
>>108420124Xe probably thinks it's impossible to put structs inside structs, and that C doesn't permit recursion in data storage.OK, "thinks" is a strong assertion.
>>108419797> didnt provide simpler form> didnt mention strings arent therei dont like variable types btw, uint32_t. those signed cosplays are for non-optionated c++. size only matters when it matters, when theres significant (not signed) amounts of data in the buffer (not string).>>108419870i didnt understand
The only reasonable programming language: https://shenlanguage.org/
>>108419049don't use malloc/free too deliberately, identify lifecycles shared amongst a host of objects, allocate them in an arenabut in general: read code other people have already written
>>108419478innitunfortunately 2029 is 3 years away and waiting for C29 to trickle down to embedded compilers will take ages
>>108416319Strange, since it seems every programmer in other languages continuously keep writing solutions to problems that aren't there.
>>108419710and all that but without runtime pessimisation
>>108420142I'm not too sure actually.vidrel kinda made me appreciate how, at its core, the borrowing system is quite simple: https://www.youtube.com/watch?v=lVWiHIVXG2c
>>108417101x)Rust is lockedNim have 0 documentation And zig? well it is most ambitious from all three but more holes as C itself maybe in next 10 years will be ready and usable!!!But who is going to use it !I do not know considering plague of Vibe Plebs demolishing whole Code base knowledge...
>>108418657based
>>108420124I didn't mean literal data structures, but rather structures in general. Look at what C offers:- arrays that don’t have a size (just a chunk of memory)- unions that are not tagged- structs that have a fixed size- enums that are just constants in disguiseCompared to sets in Pascal enums are very primitive. Even functions like printf and similar ones feel somewhat primitive. You already have a non-CFG grammar, at least give me the power to overload functions.>>108420170>the primitive form is the best form.The fun part is that our modern tech stack has been built over decades of accumulated technical debt and accidental complexity. It is far from being primitive, and it’s much less perfect than one might expect.
>>108418657Last time when I have presented my superlight , 100x faster solution in assembly code to my Python peers , they all were standing there like deer in headlights...Now I have job and from 10 pythoners 2 left others were AI- ied.
>>108420643>arrays that don’t have a size (just a chunk of memory)Saves space, since you usually have a length variable somewhere near it anyway.>unions that are not taggedTag it yourself.>structs that have a fixed sizeWhat language doesn't have this?>enums that are just constants in disguiseTag a union with them and it'll be whatever you want.>You already have a non-CFG grammar, at least give me the power to overload functions.Then you'd have name mangling and all the downsides that come with it, mainly way worse ABI compatibility between compilers. There's a reason C is the only language with a stable ABI.