What is my opinion on this language?
ziggers tongue my anus
Better than the other supposed C replacements like Odin and Go because it can build itself so it isn't just a glorified LLVM frontend anymore like Odin and doesn't require a gay runtime like Go. Nice that it can directly include C headers.But does it have a reason to exist when C exists?
>>108800800>But does it have a reason to exist when C exists?yes, because C is 54 years old.
>>108800800modern features and a non-primitive toolchain are good and nice to haveat least they would be if they language would release 1.0 and stop making breaking changes
>>108800893> breaking changesThat's good, actually. Look at what have C++ become with their 'no breaking changes' policy.
>>108800703what >>108800800 saidimo the only real C alternative that has any traction
>>108800703Seems competently designed but it's unusable trash until they at least specify a stable subset of the language that can be depended on long-term. Half the reason people use C is future-proofing, and Zig provides zero stability guarantees.
>>108801077it was shit before 98 already.
The zig creator is the only competent programmer and language designer of the crop of current "systems" language developers. This is clear from the way he discusses technical issues and design choices.However, the language has a lot of warts especially related to verbosity due to some well-reasoned but poorly implemented stances, e.g. explicitness in type casts without proper sugar for it.I have been saying since before zig was anywhere public in all these discussions and sometimes even TO these people not to use llvm for exactly the reasons they moved off of it, but for some reason, nobody listens until it's too late. Other than that, there are plenty of features from ancient languages that it could implement, but doesn't, in the supposed name of simplicity (particularly around how to structure comptime properly) which are unfortunate.That said, it is still the "c-replacement" language I am most hopeful for, beside my own (which is more inspired by forth than c and thus would never be widely adoptable, unlike zig).I also agree with what other anons have said: until zig becomes stable, it will not be usable for serious work. In the early days of rust 1.x, this was also an issue, with only maybe 85% of 1.0 crates still compiling nowadays, if that (and only because, due to lack of tooling in the 1.0 days, there would have been fewer dependencies, which is a key breakage vector in rust).Python is another good example. The 2 to 3 transition was notorious, but 3.9 programs don't work in 3.10, 3.11 programs don't work in 3.13, etc. which makes docker-oriented development and deployment the only way to work with python, and also means that you have to know each dialect variant to maintain an ecosystem of python programs. It is insane, and I think people are starting to finally understand this to be true and to once again start valuing language stability.
>>108801161Great post. Out of curiosity have you tried Jai? I'm wondering how it compares>explicitness in type casts without proper sugar for itthis is really the only thing I straight up hate about the current syntax. Even having done some projects in Zig over the past year it's still obnoxious.
>>108800703same problem every c/c++ replacement hasWHERE IS THE ECOSYSTEM??
>>108801077There has to be a sane middle between backwards compatibility and constant change.
>>108801077breaking changes between language standards is fine, ABI autism is why sepples sucks
>>108801206zig probably has the largest ecosystem out of any memelang now that Rust has graduated to Real Language status
>>108800800>But does it have a reason to exist when C exists?no macrosbuilds and testsslice stringsuseful stdlib
>>108801224I hope Zig remains small, I would suggest that they cut down on the basic primitives of the language. maybe even try to mimic something like lisp in terms of simplicity.
>>108800703irrelevant since Rust mogs it entirely.
>>108800703zig is just a weird wrapper around a fully functioning, multi-target, multi-glibc (and even musl) targetting C and C++ toolchain.that's what you think of it. zig, the language, is pointless and homosexual.
>>108801224rust is not ready for primetimenot even close
>>108801327no one cares what your irrelevant ass thinks, kiddo.
>>108801161New IO is a defacto downgrade and causes dynamic dispatch every single time with a fat ass vtable.This is coming from the same team that switched to intrusive data structures because the allocator interface was too bloated and was stored as a field inside the structure. The verbosity is through the roof to the point where even Rust looks decent compared to Zig. Their compiler still sucks. It does lazy compilation which makes fixing errors so fucking annoying it's insane. They have utter retard stuff like unused variables as error. Like fuck off. At its current iteration zig is utterly retarded to use and harms developer productivity. I have no problems with the language aside from general verbosity but some of the decisions by the core team are not only questionable but downright retarded.
>>108801349Its tiresome having this discussion because no one does it in good faith - you act like if Epic wanted to they could start replacing everything in Unreal with Rust and it would be smooth sailing.That's not even fucking close to true. They'd have to vibe code god knows how many libs to reach parity with what they are already doing in C++.The ecosystem is just not there yet. Its funny merely stating fact causes so much seethe.And yeah, zig is even worse off. Much worse. Odin is worse than that even. This is why c/c++ will never be replaced. People do not take this issue seriously.
>>108800800Functionally, Golang isn't a C replacement it's a Java replacement.
>>108801161>It is insane, and I think people are starting to finally understand this to be true and to once again start valuing language stability.Go won.
>>108801365i was actually gonna spend a few months with zig but then i saw someone on youtube writing a project in it and it's so fucking verbosewhy do people torture themselves like that? it's not even useful verbosity, 95% of the time you dont need it and for the 5% they shouldve just added a scope
>>108800703well obviously
>>108801412I don't care what Epic does or does not do. It has nothing to do with Rust or its ability to make real world software.Firefox's wgpu is Rust, there are games and game engines in Rust and there are physics and linalg shit in it too.none of this really matters though, but the point is they exist, thus proving the language does real shit. you want to deal with retarded shit like C++? then keep doing whatever you're doing. don't come crying when your shit crashes and you have vibejeets throwing 0days at you through your security@ though.
>>108801474>game engines in RustFyrox and Bevy? c'mon man. not ready, not by a long shot>none of this really matters thoughevidently not, I mean Rust enthusiasts sure in the fuck don't seem to care so why would anyone else?>you want to deal with retarded shit like C++? then keep doing whatever you're doing. don't come crying Exactly what I mean about not engaging in good faith.>you don't want to rewrite Unreal in Rust and all the modules needed to support it? Then fuck you don't deserve to rust go back to c you loserLike sure I'd like a c replacement but I am not rewriting the whole ecosystem myself, sorry
>>108801474his point wasnt that you cant write stuff in rust his point was that rust isn't stable and battle tested enough to be the best choice for writing stuff in
>>108801499it's a retarded sentiment then. no one is stopping him from starting today.
>>108801495You wrote all that comment in 3 minutes? impressive (((anon)))
>>108801412>>108801474I'm waiting for the industry to catch up to pure languages (haskell, lisp, smalltalk). I'm tired of C/C++ clones.I'd write it my self but im not skilled enough yet.we can have performant pure languages I believe
>>108801495>why aren't poeple doing shit for me for free to my standards?just kys faggot. I swear to fuck. I don't care. You're literally just wrong as you already self-admitted.
>>108801511none of these replies are made by real people
>>108801523maybe, but you have to do the work or put the money up.Unreal and Unity are products that don't make enough money for their (((owners))) as is and are basically mutil-million man-hour giga timesinks to compete against with little to no profit incentive and significant risk of total loss. this basically goes for most all real world software where the competition basically doesn't exist. hopefully we see a real dotcom level crash in all of tech so maybe we can fund better software tomorrow, but I doubt it will happen anytime soon.
>>108801547Unreal is notoriously inefficient. Unity logo makes sphincter clench in anticipation of cringe.>inb4 ure holding it wrongSo much for those multimillion man hours...
>>108801592life is full of trade-offs. You lose things along the way trying to make a system that allows AAA and AA studios make games with the bing bing wahoos and shit people expect for 60+ dollarydoos. We live in a world, as well, where you have to export as much of the things that aren't your "core competency" to boost profits as much as possible. Doesn't help that companies that still bother maintaining their own in-house engines ultimately lag behind in some respects as well.
>>108801523>I'm waiting for the industry to catch up to pure languagesPeople have been waiting for this since the 90s. It's not going to happen
>>108801523Rust enforcing single mutable xor many readable literally solved like 90% of the problems that made me care about purity, honestly. I was floored how much it did.
>>108801161ReleaseSafe zig code has to be 100% safe, runtime overhead is fine. can always mark hot sections with ReleaseFast, but most programs have lots of boring scaffolding, can't have buffer overruns there bring the entire thing down
>>108801511Thanks, I guess?>>108801506Its not that simple, even the windowing libs still have bugs to be worked out. Cross platform is hopeless atm. Again, not really picking on rust its a general c replacement problem. Zig is even worse off. I just don't see us even replacing c at this rate especially with AI coding now who even cares?
>>108801202I'm not in the beta or whatever contrived access scheme he's been going for these days, so I haven't tried Jai. I haven't kept up all too much either because what's the point when it will only ever be available in Two More Weeks (tm) (and can change considerably in that time), but I haven't yet seen any particularly interesting feature. I am, however, very interested to see what happens when it finally becomes available.
>Zig
>>108800800>But does it have a reason to exist when C exists?This.
meme lang that people want to pretend is better than it really is just because it's a modest improvement over C
>>108801412>Its tiresome having this discussion because no one does it in good faithYou started off on bad footing by fixating on an imprecise claim of "ready for primetime." You perceive responses as bad faith due to your own semantic carelessness.Case in point:>you act like if Epic wanted to they couldThis is, in fact, the bad faith argument. You're putting your headcanon in his mouth then arguing that straw man.
>>108800858C23 is the last standard
>>108802347New C standards just add things, they don't change the language.
>>108802002It was leaked here on /g/: https://desuarchive.org/g/thread/106051377/#106077531The main reason why you'd want to try it over Zig is if you feel like Zig is too verbose and slow to get anything done with, or if you want to use the pre-packaged libraries for graphics, UI or other game related stuff.
>>108802043Because writing C is a pain in the ass.
>>108800703It's pretty good. You can disregard people who complain about syntax. Explicitness is good. Errors on unused variables are sometimes annoying but probably overall a net positive.Yes the language and stdlib break a lot but every time it did it's felt like my codebase improves when I rewrite it to fit.They finally capitulated on their "result location semantics" idea which to me was always the "zig has no footguns except for this one thing" idea.The new Io is divisive and doesn't seem to be built with compute scheduling in mind, but I still have to try and make that work and they will still probably iterate on the Io design.Being able to compile zig -> spirv is really very nice but it's a bit undercooked at the moment.@Vector is a terrible name but I think they recently decided to change it.Build system just werks.They really care about getting details right which makes for a pleasant toolchain.
>>108802410Thanks for the link, interesting.My core issue at any rate is still that until it releases and is generally available, it's kind of waste to have any grand opinion of it (but it is an interesting curiosity at this stage).I don't really get the point of these languages with pre-packaged libraries like these, though. Much nicer to simply somehow make appropriate libraries easy to access, rather than actually being included. I understand that the point of Jai is to make games, but then games are not so trivial (like a entrepriseware despite program and its GUI) that the systems can be standardised in a one-size-fits-all manner. I would even be wary of any protocol standardization beyond very low level stuff. I picture as a test case the transition from opengl/vulkan or dx11/dx12, for example. At any higher level, that becomes even trickier.I'll take a look and see if I understand any useful rationale behind this choice here or if there are any interesting features.
>>108802699>I don't really get the point of these languages with pre-packaged libraries like these, though.I think it pretty much boils down to Jon thinking that the "normal" libraries suck and wanting to make his own ones. He's had many rants about how much complexity and bullshit you have to go through just to draw some triangles on the screen.
>>108802392C11 admitted that SMP was a real thing and kneeled to C++ memory model, oh and threads, but people still just use pthreads.
>>108802336As far as I can see there's no reason Unreal 6 won't also be in C++, and that's a very major player. I don't see how that's a strawman, its just reality.Rust and zig are the same in that neither of them are ready. Not even close. Maybe by 2040? Certainly not 2030 at this rate.
>>108803364No one gives a shit what Timmy is doing with UE6. It still has nothing to do with Rust being ready or not.
>>108800703The only good thing made with it - Bun - just switched to Rust this week. It's over.
>>108800800Odin is a replacement for C++ for DOD game development.
>>108800703It's a good C replacement that won't see sufficient adoption.
>>108802549>Explicitness is good.not always, especially when the language basically forces you to fill your function parameters with bunch of nonsense. now with the async io stuff it's going to get even ridiculous, something that languages like Jai and Odin were smart to avoid with their context systems. why not just write assembly if that's your stance?
>>108802392Most examples in K&R 1st edition don't compile anymore in C23
>>108801523>>108801797>It's not going to happenCorrect, especially not now that LLMs can help enormously with the scutwork required by the more performance-oriented languages.And there in reality is no "pure" lisp even among Lisps. Racket is probably closest and it's also probably the smallest niche of the three practical lisps.
>>108803316Which he is right about re: the ceremonies required to put a triangle on-screen. However, that belongs in a library, not in a base language is my point.
>>108804153Chicken is better than racket among schemes and scheme-likes. Common lisp is the most practical because the implementation is way better.
>>108801161>effortposting instead of just calling the language gaycringe
>>108804013>forces you to fill your function parameters...as opposed to what?>why not askAssembly is not explicit in the sense that it's more difficult to read and understand.
>>108805051Not him but>...as opposed to what?The operative phrase is "with [a] bunch of nonsense", not "fill your function parameters". >Assembly is not explicit in the sense that it's more difficult to read and understand.There does not exist any definition of "explicit" where your interpretation is entailed.
>>108801523>we can have performant pure languages I believepure languages don't work the way the computer actually works so not really
Since everyone is migrating off of zig. Is it even worth using it anymore? Whenever I've tried using it I just run into annoyances with it.
>>108800703https://desuarchive.org/g/thread/108770946
>>108805119I didn't put all of it in the quote. the "bunch of nonsense" I'm not sure what it could even be referring to. Allocators being passed to functions that allocate? With the comment about assembly I meant that you lose a lot of context the type system and comptime and even variable names provide.To me this means it's less explicit that for example a parameter represents an Io interface since you can only observe lower level things like chasing a function pointer and performing a syscall.Thus you do lose information that is spelled out in the zig source code in this case.Regardless the point was not to argue whether assembly is explicit or not (but I take your point I suppose), but rather that the idea of writing assembly instead of jai/odin/zig/c/... is orthogonal to whether or not explicitness in a high-level language (i.e. spelling the relevant details out) is good.
>>108805448Neither does C.
>>108805882C is way closer than functional languages
>>108804827Common Lisp is also as pure as a bucket of gravel.
>>108800703I've heard ziggas are losing their prize project to r*st
>>108806073Purity is for niggers>>108805973Of course, but don't move the goalposts.
>>108806272The goalposts are "functional languages are way too abstract to be peformant", C has nothing to do with that
>>108806276No, the goalposts were: pure languages don't work the way the computer actually works so not really.Bonus protip to address the goalposts you moved: all modern high-quality compilers compile to SSA as an intermediary step, which is a pure language.
>>108806402>No, the goalposts were: pure languages don't work the way the computer actually works so not really.Which still has nothing to do with CSSA is not pure
>>108806439C is often compiled to SSA first e.g. by clang. SSA is pure. www.google.com ur whalecum.
>>108806735SSA is as pure as C, as in if your code has absolutely no side effects then it's pureThis is a meaningless thing to say
>>108806740You have no clue what SSA is or what C is. That's OK, not everyone has to know everything. But there is this thing it's called google. Surely you know google. Use it before making a fool out of yourself.
>>108806753I have written a compiler that uses SSA
>>108800703It's pretty based.>>108801105Same goes for rust but that didn't stop the hype train.
>>108804067eh, most do, and all with very minor alterations
>>108801161>beside my owndoes it have a name and is it public anywhere?
>>108806860Judging by the fact that he's calling everyone else dumb we can safely assume his language doesn't exist
>>108805882oh but it basically does
>>108803364Linux(the actual kernel, the drivers are separate) will always stay in C, Windows always will, GCC/Clang will always stay in C++ as will Unrealyes indeed, large legacy codebases can't just change their implementation language like that
>>108806860It's called Frisk and it is not public yet, although I have two abandonware earlier prototypes of it on my public github.I will also put that on github if I either move on or I find that it's sufficiently complete to get there, but frankly, I don't think it will appeal to much of anyone. It is very specialized to my special blend of tastes after all.
>>108806883Not even remotely. We're not running pdp-11's anymore.
>>108807878You literally cannot think for yourself and repeat false information you read on a blog
I like odin because it's like C but with less noise and is just delightful to work in and readzig has more noise, so I don't like itI want to actually make things
>>108807927ThisPeople crying about muh llvm frontend are just parroting memes trying hard to look cool for the /g/irls(m).
>>108807940>muh llvm frontendI've never understood why this is an issue
>>108807878you do not know what the PDP was, quoting an article's catchy title does not make you smart.>>108807906I hate that blog entry
>>108800703Meme language that is persistently shilled here by Andrew. Every single zig thread evolves into language war because that's the only way to keep them alive. There is always so many very real people claiming to use it, but for some mysterious reason no one ever posts any projects or code made in zig.Buy an ad.
>>108808047I'm quoting it precisely because it's catchy, but I know pretty well the architectural differences between these "kinds of" architectures and modern ones and why this is indeed an apt statement despite the soirage you trannies have over it.
>>108807940The problem with LLVM is that every change breaks both the frontend and the IR. It's a broken piece of absolute trash and takes a team of 20 fulltime engineers to keep up and fix each version if you want to stay up to date. So small projects just freeze a very old version and call it a day, but then the whole language is tied to a fuckhuge massive runtime for no fucking reason.
>>108808121>I know pretty well the architectural differences between these "kinds of" architectures and modern oneswhat are they then
Your opinion is that you like it, and you will use it in your future projects. Capicchi?
>>108808135At a very high level and keeping only to key talking points: superscalar and out of order execution, parallelism, fpu's as standard (vs optional), fuck huge increase in amount of (physical) registers (and huge increase in virtual/user-addressable registers too), unibus vs plethora of crap (pcie, dma, etc), microcoded instructions, direct vs indirect two address memory addressing capabilities come to mind.
>>108808130I'm not saying LLVM is great and think Zig made a smart move away from it. But it's also not a reason to completely ignore a language that otherwise delivers what you want.
>>108808204C's design plays perfectly well with most of those things
>>108808236C is a garbage language and so is Zig and Rust and C++.
>>108808453which language do you like?
>>108808506I'm a pure language only type of girl
>>108808524I'd figured!
>>108808226It is a valid reason for a variety of technical reasons, but overall the sane stance is to ensure the language has a real plan to move off of llvm "eventually" (within a reasonable timespan) AND has what you want.Otherwise I'd just use opendylan, which is an excellent top-tier language (except I don't want fucking boehm gc in my language, what an abomination).
>>108808236It's ok that you don't understand any of these concepts, but you should look them up or ask about them instead of saying retarded shit like that.You should also look at the C virtual machine described in the C standard before saying something so inbred-tier.
>>108808530>It is a valid reason for a variety of technical reasonsname them
>>108808533>no arguments only ad-hominemI accept your concession
>>108800716fpbp
syntactically Zig in the Zeitgeist of half-ass abbreviated keywords, greatly salted with special symbols/punctuationruntime features are optional like in C++.so the Q of replacement of C with a "better C" that is C++ has the same answer - evolution of half-assed runtimes is futile, doesnt lead anywhere.
>>108808536LLVM is very large and maybe you want to use the language toolchain on a small device (i.e. not target the device but use the toolchain on it). LLVM doesn't support all the platforms very well, maybe your platform target is a bit exotic.LLVM frequently has regressions and various bugs. It is very hard especially in an experimental language to tell if you are encountering a bug in your code, in the language, or in LLVM, compared to if the toolchain is fully owned.More meta, but use of LLVM can greatly constrain the language devs either through having to work on the LLVM interface instead of the language (see: breakage) so less bandwidth to make the language better, or by constraining language design to better map to LLVM's better quality optimizations.
>>108808716LLVM sucks because you might want to compile on a Raspberry Pi? Is that the best you've got?
>>108801317I think it could be good as a cross-platform compilation helper (rust already uses zig for this purpose with zigbuild) and as a low-level glue language for C libs. If Ziggerman himself doesn't fuck the language up then I can see it slowly becoming really common as people just use it more and more.
>>108800858invalid argument. the spoon is more than 54 years old and we use those.
>>108808732Do you have severe brain problems?
>>108808798what other small device are you going to be using? who fucking compiles on anything that isn't a PC?Your other point is "well maybe bugs", no shit, all compilers has bugs, not a valid argumentthe other one isn't an argument at all
>>108808808Even an AI can't make a post this retarded. LMAO!
>>108808821>make a post that appears intelligent but isn't actually correct>completely crumble into petulant insults at the first sign of criticism
>>108808833I accept your surrender. Next time, read a book. Probably about programming. This way you can learn hello world, maybe in a decade you'll understand what is being discussed in this thread.
>>108808846You're a glass cannon bro, you can dish it out but you can't take it
>>108800703Dead like all the other meme languages. Rust won. Not because it's good, because some indian with pi-mono and deepseek flash can write a better program in Rust than you can in Zig following the same spec in less time.
>>108806815Rust has a different target audience. Rust is competing with C++, where it's a clear upgrade perhaps even in terms of stability which isn't as big of a concern there. Zig is competing with C where stability is a core feature.
>>108808846No, he won. Or at least, is winning unless you can come up with something better than >>108808716, which are valid observations but nothing worth condemning an otherwise good language to the trash heap.
>>108800703Your opinion is that it's shit. Please pay $10 to purchase your next batch of thought tokens.
>>108801202>have you tried Jai?I've got one thing to say to the creators of Jai:Have a shit or get off the pot.In other words, stop sitting on things and let the code out, or resign yourself to a bunch of tools that only yourselves and complete lunatics will use. There's no technical merit possible that isn't overwhelmed by the risk of not having openly available tooling and wide public feedback. Publish officially and be damned, or be triply damned for not publishing.Leaks don't count. Despite >>108802410
>>108809756If you check the posts this is a reply to, you will find that you agree that I have won.
>>108809856No it's not, but if you want to believe that, no one can stop you.
>>108800800all lamguages, even c, have runtimes
>>108809806I predict they're going to launch Order of the Sinking Star, then polish up Jai and the build tools and release them 3-6 months later.