{"id":5966,"date":"2023-04-19T19:48:54","date_gmt":"2023-04-20T02:48:54","guid":{"rendered":"https:\/\/blackcap.name\/blog\/new\/?p=5966"},"modified":"2023-04-20T06:51:04","modified_gmt":"2023-04-20T13:51:04","slug":"where-the-rust-language-makes-sense","status":"publish","type":"post","link":"https:\/\/blackcap.name\/blog\/new\/?p=5966","title":{"rendered":"Where the Rust Language Makes Sense"},"content":{"rendered":"\n<p>Per <a href=\"\/blog\/new\/?p=5928\" data-type=\"URL\" data-id=\"\/blog\/new\/?p=5928\">this<\/a>, I think Rust makes the most sense for things you would have otherwise written in C or C++. It is a more modern, relatively low-level, language than either of these two (and is <em>much<\/em> cleaner than C++, which was an attempt to add all sorts of extra features onto C, and which suffered as a result of having to be a proper superset of that earlier language).<\/p>\n\n\n\n<p>If you were not going to write it in C\/C++, in other words if computing resource limitations are not a constraining factor, then writing it in Rust just doesn&#8217;t make sense. Use some other programming language with automatic garbage collection, so you don&#8217;t have to worry so much about memory management.<\/p>\n\n\n\n<p>Which means, that for other than embedded systems, it is generally stupid to use Rust from the ground up. Use a higher-level language like Python. If the higher-level language proves too slow or too memory-inefficient, do some profiling, find the weak links in the chain, and rewrite those in Rust instead of rewriting them in C\/C++. There&#8217;s <a href=\"https:\/\/www.infoworld.com\/article\/3664124\/how-to-use-rust-with-python-and-python-with-rust.html\" data-type=\"URL\" data-id=\"https:\/\/www.infoworld.com\/article\/3664124\/how-to-use-rust-with-python-and-python-with-rust.html\">already libraries<\/a> out there to facilitate doing the latter.<\/p>\n\n\n\n<p>And that is why I can&#8217;t feel much love for Rust: because I am right now not running up against any resource constraints that make Python, Java, or Kotlin impractical.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Per this, I think Rust makes the most sense for things you would have otherwise written in C or C++. It is a more modern, relatively low-level, language than either of these two (and is much cleaner than C++, which was an attempt to add all sorts of extra features onto C, and which suffered [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[7],"tags":[],"class_list":["post-5966","post","type-post","status-publish","format-standard","hentry","category-computers"],"_links":{"self":[{"href":"https:\/\/blackcap.name\/blog\/new\/index.php?rest_route=\/wp\/v2\/posts\/5966","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blackcap.name\/blog\/new\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blackcap.name\/blog\/new\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blackcap.name\/blog\/new\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blackcap.name\/blog\/new\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=5966"}],"version-history":[{"count":3,"href":"https:\/\/blackcap.name\/blog\/new\/index.php?rest_route=\/wp\/v2\/posts\/5966\/revisions"}],"predecessor-version":[{"id":5970,"href":"https:\/\/blackcap.name\/blog\/new\/index.php?rest_route=\/wp\/v2\/posts\/5966\/revisions\/5970"}],"wp:attachment":[{"href":"https:\/\/blackcap.name\/blog\/new\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=5966"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blackcap.name\/blog\/new\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=5966"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blackcap.name\/blog\/new\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=5966"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}