Originally posted by rabcor
View Post
Rust-Based, Memory-Safe PNG Decoders "Vastly Outperform" C-Based PNG Libraries
Collapse
X
-
-
-
Originally posted by YBoy360 View PostThe problem is how to use this lib in real world, if it cannot be linked. C can be linked everywhere.
Comment
-
-
Originally posted by iq-0 View Post
Code:use strict; use warnings; use AnyEvent::HTTP; use JSON; sub fetch { βββ my ($url, $cb) = @_; http_get($url, headers => { accept => 'application/json' }, sub { my ($data, $hdr) = @_; die "Failed to fetch $url" if $hdr->{Status} !~ /^2/; return $cb->(decode_json $data); } ); }β
Comment
-
-
Originally posted by duby229 View Post
Have you ever tried multithreading in C? It is hard, coherency is really difficult. There are some APIs now to help, but still it's very difficult. It's incredibly easy to write code that corrupts it's own self. C itself was never designed for it. It can be done, but incredibly hard to do right. You can easily write code that doesn't work at all and then never be able to figure out why.
Comment
-
-
Originally posted by smitty3268 View PostSeriously, which parts are confusing?
Comment
-
-
Originally posted by TheMightyBuzzard View Post
Like most everything else in programming, it's only hard if you don't know how to do it. You have to learn how to do it in Rust as well or your code won't even compile. The only difference is Rust tries to hold the hands of people who didn't bother to learn before they started writing.
Comment
-
-
Originally posted by back2ζͺδΎ View Post[ just for completeness, same functionality with Cpp:
Code:... // Callback function to handle data received from libcurl size_t WriteCallback(void* contents, size_t size, size_t nmemb, std::string* out) { size_t totalSize = size * nmemb; out->append((char*)contents, totalSize); return totalSize; } ...
Comment
-
-
Originally posted by TheMightyBuzzard View Post
And that right there is a major reason why I'm not a fan of so many Rust projects or Rust fanbois. They like to call something "production-ready" as soon as they think they're done writing the code (or even before in many cases). Production-ready actually means something though. I know that's easy to overlook in a time when changing definitions to suit your desires is so common but it's important to remember that it's only you and your equally deluded friends that actually believe that crap when you do it.
Comment
-
-
Originally posted by Mordrag View PostTell me you haven't written Rust without telling me you haven't written Rust. Please go to crates io and lookup some popular crates. It is ridiculous how many are still not 1.0.0 with great documentation and dx overall. I've never seen that kind of quality control in any ecosystem except Rust's.
Comment
-
-
Originally posted by sdack View PostRust was created because people are having skill issues.
Comment
-
Comment