4 ms·
I find I don't really care about that list, aside maybe trying to resolve the namesquatting problem in cargo. My reduced list includes only: * Strong typesafe
by Luker88 4y ago
I find I don't really care about that list, aside maybe trying to resolve the namesquatting problem in cargo.
My reduced list includes only:
* Strong typesafe wrapper types. We had a few RFCs, always dropped. This would actually change how I program, and would increase typesafety a lot. I don't even need fancy wrapping with the ability to select which traits to expose and which not, just wrap+automatic expose would change my life a lot
* Let me compile to shared libraries. I get it, all-static has its pros. But refusing to support shared libraries is asinine. It's fine if I have to always use the same rust compiler version! just give me the possibility!
- ModernMech 4y ago> Let me compile to shared libraries. I compile Rust to shared .dll and .so libs all the time. Is this what you're looking for? --crate-type=dylib, #[crate_type = "dylib"] - A dynamic Rust library will be produced. This is different from the lib output type in that this forces dynamic library generation. The resulting dynamic library can be used as a dependency for other libraries and/or executables. This output type will create *.so files on Linux, *.dylib files on macOS, and *.dll files on Windows. https://doc.rust-lang.org/reference/linkage.html https://doc.rust-lang.org/reference/linkage.html
- Luker88 4y agoNo, I guess I wrote the message too quickly and explained poorly, my bad. I meant compiling a program and linking the crates as shared libraries. Kinda like a normal C/C++ program, and how the whole linux wolrd works. ...and I guess even the strong newtype wrapper is actually there with `struct Newtype(type);`, but I end up having way too many `.0` everywhere that I really dislike I'll try not to post before my morning coffee next time :p
- ModernMech 4y ago> I meant compiling a program and linking the crates as shared libraries. Okay I see. You can kind of get this from the libloading crate. https://docs.rs/libloading/latest/libloading/ https://docs.rs/libloading/latest/libloading/ It works but it’s not great.