48 ms·
I modded you up because clang is written in C++ and even if I didn't know this I'd suspect it because segfaults in languages that are not weakly typed (i.e., C
by golemotron 12y ago
I modded you up because clang is written in C++ and even if I didn't know this I'd suspect it because segfaults in languages that are not weakly typed (i.e., C and C++) are incredibly rare.
There are better languages to write compilers in. OCaml is one.
- nly 12y agoC++ probably isn't 'weakly typed', whatever that means.
- yzzxy 12y agoYou probably aren't "qualified to make that statement", if you don't know what weak typing is and are too lazy to google it.
- nly 12y agohttps://en.wikipedia.org/wiki/Strong_and_weak_typing https://en.wikipedia.org/wiki/Strong_and_weak_typing > In general, these terms do not have a precise definition. Rather, they tend to be used by advocates or critics of a given programming language, as a means of explaining why a given language is better or worse than alternatives.
- mateo411 12y agoC is weakly typed, because you can cast or set any variable to be a void *. Since C is weakly typed, then you can write a C++ program that is also weakly typed.
- timshen 12y agoI'd rather say that C++ "fixes" C's unsafe type system by making some of the castings legal, instead of safer :)