Anonymous
How does it proof that C++ have more overhead than C?
Nils
Use Boost.Multiprecision for example
LOL I need to solve this on hackerrank
Nils
And they do not have boost
Anonymous
You're casting the result
Nils
Ohh I see. So I have to cast each number?
Anonymous
But you should cast an operarnd
Nils
the first one right?
Ehsan
How does it proof that C++ have more overhead than C?
I don’t mean overhead in performance,
Anonymous
You actually can use ull suffix
Nils
ahhhhh
Nils
thanks!!
Anonymous
Ehsan
edited it
Anonymous
Version control system is not a low level thing..
Anonymous
Mercurial is written with Python
Anonymous
The fact that git is written with C doesn't make VCSs low level
Anonymous
There are operating systems in C++
https://github.com/SerenityOS/serenity
Ehsan
Mercurial is written with Python
which is faster Danya ❤️
Anonymous
https://github.com/SerenityOS/serenity
It's probably not a mature system, but still a good one
Anonymous
it's just because linus prefers c
I'm aware of that, yes
Ehsan
https://github.com/SerenityOS/serenity
I didn’t say you can’t make operating system with c++ man. in low level applicatins you work so close to the hardware, you don’t really need any additional functionality, everything is available in c.
Anonymous
Even C that compiled with C++ compiler is better than just C
Ehsan
it's just because linus prefers c
windows was made by linus right?
Anonymous
windows was made by linus right?
linux was made by linus
Anonymous
windows was made by linus right?
Windows is at least at half written in C++
Aakash
And it's not supported yet constexpr std::string is not a string literal🤔
#include <iostream> template<char const **p> class X { public: void run() { std::cout << *p; } }; const char *zp ="Studebaker"; int main() { X<&zp> x; x.run(); } 🙃
Prince Of Persia
Anonymous
So why linux is in C?
Because Linus Torvalds doesn't like C++
Anonymous
what?
Anonymous
what?
I linked to a message from this chat
Prince Of Persia
I linked to a message from this chat
So don't do that again😂
Anonymous
Windows is also moving away from C++
Anonymous
To rust
Anonymous
Anonymous
Windows is also moving away from C++
I don't think so :) With the 21 TB repository
Ehsan
the kernel is the core of the operating system
Ehsan
and almost all operating system, the kernel is written in c
Ehsan
unix/linux/windows
Anonymous
I don't think so :) With the 21 TB repository
https://msrc-blog.microsoft.com/2019/07/22/why-rust-for-safe-systems-programming/
Prince Of Persia
Windows is also moving away from C++
C++ is anywhere Even if in C C++ is good for programming and C have gotten some futures from C++ like bool and inline
Anonymous
Considering the amount of security issues with it
Ehsan
C & Assembly
mostly in c
Prince Of Persia
C++ is quite bad tbh
C++ is the best
Anonymous
Even C doesn't mess up this badly
Prince Of Persia
Anonymous
There are entire C++ libraries like QT that memory leak right at initialisation
Ehsan
it’s really stupid to write the kernel in c++
Ehsan
there’s no reason other than making a bigger code
Prince Of Persia
it’s really stupid to write the kernel in c++
Yeah but C++ is more easier to use
Anonymous
C++ is quite bad tbh
Why rust is bad: https://github.com/pyca/cryptography/issues/5771
Anonymous
C++ is the best
Sure, it's responsible for at least 86% of security vulnerabilities
Anonymous
Prince Of Persia
it’s really stupid to write the kernel in c++
But many things like games and graphic things are in C++
Anonymous
"rust is bad because it doesn't support my arch"
Anonymous
I can also say windows is bad because it only runs on x86 and arm
Anonymous
Though x86 is legitimately bad
Anonymous
"rust is bad because it doesn't support my arch"
Yes How can you call a language is good for system programming if it supports 2 arches? :)
𝙑𝙚𝙙𝙖𝙣𝙩
Anonymous
Anonymous
I can also say windows is bad because it only runs on x86 and arm
Comparing os and a programming language Nice
Ehsan
@unterumarmung rust is used because it’s safe and reliable 🙂 it’s so easy to manage memory with it
Prince Of Persia
𝙑𝙚𝙙𝙖𝙣𝙩
Never tried
Same 😅 I like Android and windows pretty customizable for me according to my choice