*solves programming*

*solves programming*

Attached: rust lang.png (1024x1024, 509K)

*makes a 10 GB compiler*

Attached: 1550208279467_6fq8w07qm.png (644x800, 54K)

COPE

But in reality, rustc is 11MB, and everything together from ~/.cargo/bin is 270MB.

>he thinks rustc is 11MB
it's dynamically linked mate. In reality it's significantly larger. 1GiB or so.

Attached: laughing man.jpg (1280x720, 61K)

Doesnt rust require LLVM, 100mb of source? Why not use tcc to compile c? It compiles code 10 times faster than, produces optimized binaries with near gcc speed, and the entirity of the source code is only 2 or 3 megs. The binary itself is less than 300k.

Multiple compilers is the last thing Rust needs.
It doesn't matter how large is your compiler all that's important is compatibility, supported features, compile time optimizations and then speed of the compiler itself.

>doesn't have HKT
heh, not so fast

But in reality:
~/.cargo/bin$ ldd * | rg -o /\\S* | sort -u | xargs -L1 -- du -bh
32 /lib64/ld-linux-x86-64.so.2
12 /lib/x86_64-linux-gnu/libc.so.6
13 /lib/x86_64-linux-gnu/libdl.so.2
99K /lib/x86_64-linux-gnu/libgcc_s.so.1
12 /lib/x86_64-linux-gnu/libm.so.6
18 /lib/x86_64-linux-gnu/libpthread.so.0
13 /lib/x86_64-linux-gnu/librt.so.1
14 /lib/x86_64-linux-gnu/libz.so.1
2.3M /usr/lib/x86_64-linux-gnu/libcrypto.so.1.0.0
425K /usr/lib/x86_64-linux-gnu/libssl.so.1.0.0

don't even bother to expose that retard

>HKT
Useless.

only solves some memory related bugs, not logic bugs, so no programming for you if you're a brainlet

atc is coming soon(tm), hkt might be on the table

>this is the state of rust morons
holy kek

Did I make a mistake? The total size of all the binaries in ~/.cargo/bin, along with everything reported by ldd for every binary in that directory, is about 280 MB. In theory they could dynamically load libraries in a non-standard manner that ldd can't detect, and they can obviously call out to other system binaries which wouldn't be reported by this. I guess the only real exhaustive way to do this would be strace a compilation and report every file it loads, if we're counting anything it touches on the system as part of the total size.

I'll give that a try, hold on.

$ cargo clean && strace -e trace=file cargo build 2>&1 | rg openat | rg -o /\\S*\" | cut -d\" -f1 | sort -u | xargs -L1 -- du -bh 2>/dev/null
0 /dev/null
249K /etc/ld.so.cache
0 /home/meyer/.cargo/.package-cache
140 /home/meyer/Code/testsize/Cargo.lock
241 /home/meyer/Code/testsize/Cargo.toml
0 /home/meyer/Code/testsize/target/debug/.cargo-lock
16 /home/meyer/Code/testsize/target/debug/.fingerprint/testsize-93d019a73fa7b346/bin-testsize-93d019a73fa7b346
12 /home/meyer/Code/testsize/target/debug/.fingerprint/testsize-93d019a73fa7b346/dep-bin-testsize-93d019a73fa7b346
87 /home/meyer/Code/testsize/target/debug/testsize.d
1.6K /home/meyer/Code/testsize/target/.rustc_info.json
94 /home/meyer/.gitconfig
132 /home/meyer/.rustup/settings.toml
3.5K /lib/terminfo/x/xterm-256color
12 /lib/x86_64-linux-gnu/libc.so.6
13 /lib/x86_64-linux-gnu/libdl.so.2
99K /lib/x86_64-linux-gnu/libgcc_s.so.1
12 /lib/x86_64-linux-gnu/libm.so.6
18 /lib/x86_64-linux-gnu/libpthread.so.0
13 /lib/x86_64-linux-gnu/librt.so.1
0 /proc/self/maps
203K /usr/lib/ssl/certs/ca-certificates.crt

Based rustafarian.

Actually there are a few issues with this. ldd reports the path to symlinks, so you have to resolve them first. So my post in was wrong.

Fixed:
~/.cargo/bin$ ldd * | rg -o /\\S* | sort -u | xargs -L1 -- readlink -f | xargs -L1 -- du -bh
171K /lib/x86_64-linux-gnu/ld-2.28.so
2.0M /lib/x86_64-linux-gnu/libc-2.28.so
19K /lib/x86_64-linux-gnu/libdl-2.28.so
99K /lib/x86_64-linux-gnu/libgcc_s.so.1
1.6M /lib/x86_64-linux-gnu/libm-2.28.so
147K /lib/x86_64-linux-gnu/libpthread-2.28.so
35K /lib/x86_64-linux-gnu/librt-2.28.so
115K /lib/x86_64-linux-gnu/libz.so.1.2.11
2.3M /usr/lib/x86_64-linux-gnu/libcrypto.so.1.0.0
425K /usr/lib/x86_64-linux-gnu/libssl.so.1.0.0


Still not anywhere near 10G, and still makes the total about 280M.

Now with the strace approach, also taking symlinks into account:

totalsize.sh:
STATTED=$(cargo clean && strace -e trace=file cargo build 2>&1 | rg -o /\\S*\" | cut -d\" -f1 | sort -u | xargs -L1 -- readlink -f)
for f in $STATTED; do
if [ -f $f ]
then
du -b $f
fi
done


Summing it up
$ ./totalsize.sh | cut -f1 | paste -sd+ - | bc
48718820

~50MB

I'm pretty sure this one is actually correct.

And the actual list from totalsize.sh:
$ ./totalsize.sh
254677 /etc/ld.so.cache
10734264 /home/meyer/.cargo/bin/cargo
10734264 /home/meyer/.cargo/bin/rustc
0 /home/meyer/.cargo/.package-cache
140 /home/meyer/Code/testsize/Cargo.lock
241 /home/meyer/Code/testsize/Cargo.toml
45 /home/meyer/Code/testsize/src/main.rs
0 /home/meyer/Code/testsize/target/debug/.cargo-lock
2459352 /home/meyer/Code/testsize/target/debug/deps/testsize-93d019a73fa7b346
16 /home/meyer/Code/testsize/target/debug/.fingerprint/testsize-93d019a73fa7b346/bin-testsize-93d019a73fa7b346
12 /home/meyer/Code/testsize/target/debug/.fingerprint/testsize-93d019a73fa7b346/dep-bin-testsize-93d019a73fa7b346
87 /home/meyer/Code/testsize/target/debug/testsize.d
1593 /home/meyer/Code/testsize/target/.rustc_info.json
94 /home/meyer/.gitconfig
132 /home/meyer/.rustup/settings.toml
17992960 /home/meyer/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/bin/cargo
2358016 /home/meyer/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/bin/rustc
3555 /lib/terminfo/x/xterm-256color
1996592 /lib/x86_64-linux-gnu/libc-2.28.so
18656 /lib/x86_64-linux-gnu/libdl-2.28.so
100712 /lib/x86_64-linux-gnu/libgcc_s.so.1
1623216 /lib/x86_64-linux-gnu/libm-2.28.so
149696 /lib/x86_64-linux-gnu/libpthread-2.28.so
35776 /lib/x86_64-linux-gnu/librt-2.28.so
47288 /bin/readlink
207436 /etc/ssl/certs/ca-certificates.crt


So interestingly, though the distribution binaries are ~300MB, running the compiler on hello world (from cargo, too, not using rustc directly), and including every regular file or symlink that was statted by strace (not including directories, which could potentially have been passed to some other process) uses only 50MB of stuff.

And the total distribution size, not just including binaries and stuff that is loaded by the compiler (so not including shared libraries), but inlcuding docs and a bunch of other stuff (ie, the total size of ~/.rustup/toolchains/stable-x86_64-unknown-linux-gnu) is ~1G.

Rust is the new Haskell. Bunch of fly by night weenies who talk about how much better their language is while never building anything substantial with it.

...now if only library and tooling was even 1% as good as C++

Haskell is actually a good (elegant and simple) language though.
Rust is a hodgepodge language that is fucking gross from a linguistic POV. Honestly it would have been better if the Rust community just wrote a super secure C compiler with a lot of static checks. As essentially that is what Rust is already since it is built on LLVM. They could have just made C with a borrow checker and compiler enforced no UB.

I can only hope that a 34 year-old major commercial language has better libraries and tooling then some 8 year-old foss project. Anything leas would be sad.
What is sad is that project management in C++ is still a hodgepodge of third party solutions when it could and should be much better.

>what is ripgrep
>what is servo
>what is redox

ripgrep is just another reinventing of ack. Seriously, just use ack.

yes it's just another reinventing of ack but it's also significantly faster than most similar tools, I'm not suggesting that you switch your whole userland over to rust equivalents (like fd) but you're shooting yourself in the foot if you don't at least have ripgrep in your toolbox

Attached: 1560043550430.png (1287x537, 81K)

I actually do use exa, but sorry for ack's use case speed is not an issue. Not switching to an ack clone
Not to mention good old GNU grep, which you should know how to use anyways because most machines are not going to have ack or an ack clone installed

Won't be remembered 3 years from now.