you literally dont need anything else
you literally dont need anything else
Falling into your wing while paragliding is called 'gift wrapping' and turns you into a dirt torpedo pic.twitter.com/oQFKsVISkI
— Mental Videos (@MentalVids) March 15, 2023
I do not disagree.
Correct.
>segfaults
dont segfault, problem solved
>void *
extremely useful to avoid compiler fucking with you if you dont match the pointer type to the data type.
its kinda retarded like the pointers all have the same size anyway why are you blocking me from using an int pointer to point at strings
git gud
but i like namespaces
Modules are good enough.
i want to be able to perform compile time assertions on function calls and array accesses.
i want enums to have a known integer width.
i want namespades to prevent function and type collisions, instead of prepending the library's name to every entity.
i want to pass arrays by ref/pointer without losing length information.
i want generics that don't depend on runtime type information and void* indirection.
i want copy elision to replace initialization by output parameters.
and if it's not asking much, move semantics and destructors, or at least some way to convey ownership of an object, that doesn't rely on reading documentation, and expecting everyone else to do the same.
to name a few.
So Rust? Zig doesn't have some of that.
>copy elision to replace initialization by output parameters.
what does this mean
it's just meaningless word salad perpetrated by rusttranny shills paid by Mozilla.
What about for gamedev? Do you really expect me to use C when C++ is clearly tailored towards the object oriented nature of game development? This entire board has such a tribalistic mindset, I can understand having a few languages that you think are the best, but one? There is no language that efficiently solves all use cases.
OO design is for smooth brained gamedevs. It's all about data oriented design.
yes its called c99
do you gamedev for a living?
yeah, thought so
you don't need c++ unless you landed a job in one of the big game industry companies
indie shit is not profitable, and if you can afford to gamble with indie shit until something sticks, you were already a rich kid to begin with, and can afford to not have a job in the meantime
now if we're talking about a hobby then sure, you can meddle with your shitty indies in c++ all you want if that's what you like to do in your free time
but for a job? c is enough for 99% of them
C++ is a nightmare of a language. There's a reason that Carmack said its only really a good idea to use a very limited subset (C features) of C++. Its enormous and in the big picture its complexity will waste more of your time than it might save.
>the object oriented nature of game development?
IME most games use Entity style decomposition not OO.
Also tying your language to a particular problem decomposition style is extremely annoying.
I need to have cex
C is comfy but when it comes to actually doing any work I would rather go with C# Go or anything else that has a proper ecosystem and managed memory, hell even javascript or python if i have to (if the requirements allow for the language to be used) because guess what nagger some tools are better suited for specific tasks than others. Honestly this is the main reason I refuse to code in Rust or use javascript frameworks designed for 100 developer teams in fagman tier companies. Because while all of the safety features are nice, coding in it is a waste of time due to borrow checker masturbation and inane syntax, I would rather half ass it in Go or something have it run 3% slower and use 10 % more memory and finish the actual project instead of getting exhausted when i finish writing all of the boilerplate i would need in C that no library can provide for me. I do wish for a weak type system sometimes on other languages. Remember, the main limiting factor is not the language, its the data structure you are using. However the urge to just cast a char pointer to a struct is a hard habit to quit.
>.t former C fag
there is managed memory its called malloc and free, use it instead of hogging 70 terabytes to print hello world in python
>not writing your own heap on top of VirtualAlloc or mmap syscall
>not making it cross platform with #ifdefs
Did you just finish watching buckys C tutorial series on youtube ?
yes
why would i do this instead of just using malloc or jemalloc? serious question
>ecosystem
Mostly bullshit and consuming it means breaking your flow to read documentation.
I never finish my python side projects because of this effect.
>Managed memory
90% of the time you don't actually need to use the heap and the few times you do you can let the OS clean up after you and the very few times you can't do that because you actually legitimately need a long running service you can usually find some place in your code to clean up after something and just free a list of pointers.
If I want to get anything done, I do.
idk man
text = input("Enter text")
is a lot saner than the 6,000,000 lines of equivalent c code.
#include <stdio.h>
int main(void) {
char s[1024];
fgets(s, sizeof(s), stdin);
puts(s);
return 0;
}
You forgot the #
HolyC is even better. No linker or nagger makefiles needed.
You literally don't need anything else.
well, you still need a PDP-11
>or a processor that lies to its teeth to pass like a PDP-11
>you will never be a PDP-11...
You need a fuckton of platform specific libraries making the language useless for portability.