- cross-posted to:
- [email protected]
- cross-posted to:
- [email protected]
Safe code is a skill, not a feature.
i will never forgive C for making the type syntax be
char* args[]
instead of the much more reasonable
&[char] args
it also bothers me that
char* args[]
andchar c
are “the same type” in the sense that the compiler lets you writechar c, *args[5];
with no problems. i think the C languages would be way easier to learn if they had better type syntax. don’t even get me started on C++ adding support for
auto fn_name() -> ReturnType { … }
@affiliate Hey, you didn’t even mention that
char *args[]
actually meanschar **args
in a parameter list.god, what a beautiful language. it brings a tear to my eye
Strictly speaking, it should be
Unsafe block syntax in C++
{ ...}
That is why I use just
int main(){...}
without arguments instead.Any
void main(){...}
enjoyers?int main(void) { . . . }
for me!besides not requiring a return value, what difference does it make?
@stebo02 @Bogus5553 Neither of them require a return value, but
void main
isn’t legal C++.