HackerTrans
TopNewTrendsCommentsPastAskShowJobs

invpt

no profile record

Submissions

Adopting Clojure in a Hostile Environment (2021)

leftfold.tech
2 points·by invpt·3 yıl önce·0 comments

The Zig Parser (2022)

mitchellh.com
2 points·by invpt·3 yıl önce·0 comments

Displacement Activity

en.wikipedia.org
1 points·by invpt·3 yıl önce·0 comments

Using Wake on LAN (WOL) Across the Internet (2010)

ptere.com
43 points·by invpt·3 yıl önce·43 comments

Flutter desktop isn’t there yet

plei.one
215 points·by invpt·3 yıl önce·235 comments

comments

invpt
·2 yıl önce·discuss
If you look at the source for into_boxed_slice, it calls shrink_to_fit at the beginning before doing anything else. Hence the documentation is slightly wrong, and no copies occur.

Edit: I submitted a PR to clear up the docs: https://github.com/rust-lang/rust/pull/120110
invpt
·2 yıl önce·discuss
I appreciate the mention of Box<[T]>. I've never (or at least very rarely?) seen people using it, even in rustc, although I'm sure there's somewhere in the compiler that uses it. I've kind of gotten the feeling that Box<[T]> is frowned upon as a needless optimization because the one-word storage difference is so minimal, but I appreciate having the immutable size semantics as a way of ensuring no extra allocations occur by way of the methods on Vec.
invpt
·3 yıl önce·discuss
Yeah, I think the problem is that the memory model (computer science) article is too short, so the model ended up spitting out information from something seemingly related, i.e., human memory models.
invpt
·3 yıl önce·discuss
I asked it "what is a memory model in computer science" to see how it handles something slightly obscure. Its answer:

> The multi-store model (also known as Atkinson–Shiffrin memory model) is a memory model in computer science that describes the interactions of threads through memory and their shared use of the data. It allows a compiler to perform many important optimizations.

> More info in the History and significance section of the Memory model (programming) Wikipedia article.

It seems to think that the Atkinson–Shiffrin memory model is somehow related to computer science, which it is not. It's a model of human memory. And that article it references does not once mention the Atkinson–Shiffrin memory model. At least it's easy to verify.
invpt
·3 yıl önce·discuss
That's great to hear! When I get the chance, I'll update the article to note that custom context menus are actually supported now.
invpt
·3 yıl önce·discuss
I guess I'm thinking of Flutter's desktop support in relation to how it is on mobile. Flutter mobile does have a lot of built in stuff.