HN user

nfrmatk

116 karma

[ my public key: https://keybase.io/reillysiemens; my proof: https://keybase.io/reillysiemens/sigs/LTwexZfQsFoXI3JyxNAEr4CF5PtVBJsEsFxqVGrInHc ]

Posts5
Comments32
View on HN

It seems to me that the point of the article is that "all the demand" is not just for C++, C, Java, Typescript, Python, etc. There is increasing demand from larger companies for Rust.

No one is forcing you to learn Rust. You don't have to bring yourself spend time learning it. You can keep writing those other languages.

Those languages have been around for a while and they'll continue to be around for a while more. Rust is just getting some time on that stage as well now.

That's the most constructive takeaway you have when looking at all their work? That's an unnecessarily limited view and doesn't add to the conversation.

From my vantage point their work fits the definition nicely.

"A collective body" [1] ... "Collectivized or characterized by collectivism" [1] ... "A political or economic theory advocating collective control especially over production and distribution" [2]

[1] https://www.merriam-webster.com/dictionary/collective [2]: https://www.merriam-webster.com/dictionary/collectivism

In truth, that's exactly what it is. My point in writing this wasn't to say "Ooh, look at Rust being so much better". The original PHP is wonderful and there is definitely something lost in a Rust translation. Other things gained as well. ¯\_(ツ)_/¯

This blog post is just a personal journey winding through the thought process it took to replicate that PHP in Rust, something I did because I thought I might learn something.

I think Gary Bernhardt's corresponding Boundaries conference talk [1] is quite good, particularly because of how pragmatic he is in introducing the topic.

I have been thinking about and trying to work with this paradigm for a few years now. To be honest, it's been a struggle. Partly because it requires unlearning some habits and partly because there's limited opportunity to practice in my $DAYJOB where I'm working in codebases heavily invested in other paradigms.

I've seen and read many, many videos, blog posts, etc. on this topic. Everyone loves to introduce the concept with a contrived example and then stop there. What I would love to see more of are complete examples for everything from simple to complex applications.

I think there's potentially a lot of value in thinking this way (or at least taking as much from it as you can), but it's hard to learn and then to teach others without more examples to draw on.

[1] https://www.destroyallsoftware.com/talks/boundaries

Congrats to the release team! I'm really excited to work with the new structural pattern matching. This feels like the biggest language change since the addition of async/await.

Rust 1.53 5 years ago

Personally, I'd say it's worth it now. I've been dabbling in Rust for a few years and while I still don't get to use it at $DAYJOB it's been a huge benefit to me. Those "esoteric" concepts have bled into other languages and my usage of them, making me a better programmer overall. Read a chapter of "The Book" once a month or so over the next 3 years and I wager you'll find yourself in a better place than had you waited 3 years to start.

Personally, I reserve "clickbait" for links with no substance or value on the other side of the click, but I understand what you mean.

Yes, the intent of the title is to get your attention, but I'm not trying to get you to buy anything, collecting or selling user data, etc.

I really just wrote the post to share a debugging experience I had this year. It doesn't have to do with IPv{4,6} addresses themselves or any specification thereof, but it does relate to the Python 2 `ipaddress` library's handling of them and a pitfall you can accidentally find yourself in.

A dry, but more accurate title might have been

Python 2's ipaddress library considers "node.example.com" an IPv6 Address

I generally agree that the web could be simpler. A lot can be accomplished with just plain ol' HTML/CSS nowadays. I think there's a kernel of truth in what you're saying about apps vs. websites.

That said, how would you propose to do syntax highlighting instead of

just a wall of <div>s and <span>s, for every single visible character

? Rather than being a wall, it looks to me like it's actually a tree of <divs> and <span>s for every line and every _token_.

I think the author has used Prism[1], so I assume the highlighting was done client-side, but even if you were to do the task server-side I think you'd end up with similar HTML/CSS, no?

What would be a better approach to solving the same problem?

[1] https://prismjs.com/

That might just come down to the usual differences between Python and Ruby. A Python programmer would likely appreciate an explicit call to `subprocess.run`.

Some equivalent Python 3.7+ would be

  import subprocess
  listing = subprocess.run(("ls", "-oh"), capture_output=True, encoding="utf-8")
  print(listing.stdout)
  print(listing.returncode)
As an experienced Ruby programmer I imagine the code you provided looks like a no-brainer. To a Ruby neophyte the backticks, $? sigil, and .to_i method don't strike me as intuitive (but maybe they would be do someone else). We may just have to disagree about the nicety of syntax.

As cle mentioned[1], the strongest criteria is

what would the majority of people on the team prefer to use?

and I'd agree that ultimately that's what makes the most sense.

[1] https://news.ycombinator.com/item?id=24558989

Nicer syntax? Vastly better standard library? Those seem like subjective statements to me. Can you provide some examples to support those claims?

Interesting... Neat... Hilarious... In light of the submission and the comment you're responding to, these are not the words I would choose.

I think there's genuine cause for concern here, especially if technologies like these are candidates for inclusion in any real law enforcement decision-making.

I use Gutenberg (https://www.getgutenberg.io/) which provides built-in Sass compilation and live-reloading in a single binary. I just write Markdown and generate posts with Tera (https://github.com/Keats/tera ) templates for my HTML, so if I ever wanted to migrate to something else it would be trivial, but I'm a happy camper now.

When I'm ready to publish I just copy the public directory right to my webserver, but I could just as easily publish to GitHub or the like if I didn't enjoy maintaining my own domain.

Signal and Giphy 10 years ago

Why should those of us who care about privacy be required to limit the media we use to express ourselves? By including this functionality Open Whisper Systems is giving the privacy conscious a way (albeit experimental) to have our cake and eat it too.

FWIW, I am one of those people who really loves it. I'm excited for a new book, but I feel it's worth saying that the old one has been not only instrumental in my efforts to learn Rust, but also a flat-out enjoyable read. Thank you!