News for hackers. Stuff that matters.
Re:Rust in the Android Platform by bobthebuilders on Tuesday April 06, 2021 @07:42PM (#26718753)
C++ is better. Rust is a cargo cult language (same with Kotlin, Kotlin especially is a corporate language to sell more IDEs and Google was bribed by JetBraine to adopt it). Rust is just a bad attempt at reinventing the wheel.
Re:Rust in the Android Platform by howinteresting on Tuesday April 06, 2021 @09:32PM (#26719560)
Rust is a fantastic attempt at reinventing C++. It works really well. I've been writing production code in it for the last few years and it's an utter delight to use.

I maybe break out rust-gdb once a year. My code has fewer bugs than ever, thanks to extensive use of the high-quality modeling tools (types and lifetimes) provided by the language. My main project for the last year has had a grand total of one logic bug that was caught after release.

It also has an inclusive community: at the last RustConf, half the speakers were nonbinary and/or transgender. I fit both those criteria and feel more welcome in the Rust community than in that of any other language, meaning that I can do my best work in Rust.

Re:Rust in the Android Platform by carlhjerpe on Tuesday April 06, 2021 @09:50PM (#26719682)
Considering way less than 50% of developers are nonbinary/transgender, don't you get the impression that they're then trying to fill quotas rather than picking the best speakers? Not saying they weren't the best, just that either rust is a very unique community or something is "up" with the selection.

Just to clarify, I'm asking with good intent.

Re:Rust in the Android Platform by howinteresting on Tuesday April 06, 2021 @10:16PM (#26719857)
There's a selection effect: people like me experience so much ambient hostility in society that we gravitate towards communities that welcome us and that already have people like us in leadership positions. So the correct metric is not % of all developers as a whole but just the ones involved in the Rust community.

The Rust community has many nonbinary and transgender people in it, and speakers are selected from the community. The selection process for RustConf is blind so the talks were picked for their merit: it just so happened that half of the speakers weren't cis.

> rust is a very unique community

Yes, this is true in my experience.

Re:Rust in the Android Platform by carlhjerpe on Tuesday April 06, 2021 @10:48PM (#26720054)
I've been thinking about a good answer, but these days it's a fine line to talk about these things. I'm happy the rust community is so open while being widely successful. Might shine some light into the rest of the world. I'm from Sweden,where this kind of hostility probably exists, but I never see it (gay people are very well accepted, trans I'm not as certain, only have a pool of 1 friend so not enough data).
Re:Rust in the Android Platform by howinteresting on Wednesday April 07, 2021 @12:19PM (#26727083)
I'm not Swedish so I don't know much about what it's like to be a Swedish trans person.

One thing I will say is that my general impression from afar is that Europeans are generally a lot more tolerant of the state interfering in personal identity issues than the liberal parts of the US. Iceland used to have a fixed list of approved baby names for example, something unimaginable in the US.

The situation was made better in 2019: https://www.icelandreview.com/news/icelandic-names-will-no-l...

Re:Rust in the Android Platform by Rule35 on Thursday April 08, 2021 @08:14PM (#26745362)
I think the discussion gets a bit blurred around what acceptance means.

It varies from acceptance of an adult just being trans, of trans babies, of schools preaching medical transition without parent approval, and of issue of bathroom usage and sex-segregated prisons.

Regardless of the political questions presumably Swedes are fairly liberal about someone's personal choices.

Re:Rust in the Android Platform by dabraham1248 on Tuesday April 06, 2021 @10:27PM (#26719920)
It might be that people from disadvantaged communities _need_ to have more talent & insight to become experts than people like me (straight, white, male, speaks English, went to college, ...) and (I assume) you. And even more so to become _recognized_ experts. Also, they might feel more of a need to demonstrate that they should be allowed in the "club".

Put another way and exaggerated wildly for hopeful clarity, if person A became an expert despite being shoved away, and person B was wooed into the group, had tutors, friends,... I'd be more interested in A's talk than B's.

Re:Rust in the Android Platform by carlhjerpe on Tuesday April 06, 2021 @10:50PM (#26720062)
Good insight, it seems like the reply below said the talks were submitted blindly though, so that's even better. They're just accepted and doing really well!
Re:Rust in the Android Platform by anoncake on Wednesday April 07, 2021 @03:38AM (#26721517)
Somehow, queer people are subconsciously attracted to each other (not necessarily in a romantic or sexual way). While 50% non-cis is surprising, when we are represented we tend to be overrepresented.
Re:Rust in the Android Platform by wffurr on Tuesday April 06, 2021 @09:10PM (#26719417)
Rust is a bad attempt at reinventing C++? That's a unique take.

Memory safety is a big deal for writing secure programs, which has been repeatedly shown to be impossible to do at scale in C++. Provably safe parallelism and concurrency is key for performance on multi core devices, also extremely difficult to do safely and correctly in C++.

If C++ is the wheel being reinvented, it's not much of a wheel.

Re:Rust in the Android Platform by throwaway189262 on Wednesday April 07, 2021 @12:03AM (#26720468)
No way. Rust is great, trust me.

I'm not even going to say why because it would be a huge rant. It improves on C++ in virtually every way. Every feature you have in C++, Rust does it better. Every feature you wish C++ had, Rust has it.

I agree with you on Kotlin. It's better than Java on paper, but in much the same ways Groovy already was. And the advantages are shrinking in new versions of Java, especially if you use Lombok.

Re:Rust in the Android Platform by lenkite on Wednesday April 07, 2021 @04:01AM (#26721686)
"Every feature you have in C++, Rust does it better"

How does one perform generic fold expressions in Rust lang ? (Possible in C++ 17 and above)

https://foonathan.net/2020/05/fold-tricks/ https://en.cppreference.com/w/cpp/language/fold

Re:Rust in the Android Platform by pixel_fcker on Wednesday April 07, 2021 @05:27AM (#26722284)
Macros baby
Re:Rust in the Android Platform by lenkite on Wednesday April 07, 2021 @06:45AM (#26722973)
AFAIK, macros are only applicable to a subset of problems. Anyways, I found that variadic generics is a draft RFC: https://github.com/rust-lang/rfcs/issues/376
Re:Rust in the Android Platform by scoutt on Wednesday April 07, 2021 @10:27AM (#26725437)
>Every feature you have in C++, Rust does it better.

IDK. I miss variadic functions (not macros) and being able to do certain simple things without resorting to strange paradigms, like arbitrarily closing an std::fs::File without needing to go out of scope or calling drop. Things like that.

Re:Rust in the Android Platform by 3836293648 on Wednesday April 07, 2021 @12:10PM (#26726959)
How is calling drop any different from calling close?
Re:Rust in the Android Platform by scoutt on Wednesday April 07, 2021 @01:34PM (#26728097)
For the practical case is not different. But is not coherent. It’s weird. And opening/closing files is an historical concept.

Why “drop” is the opposite of “open”? Let’s change “open” for “lift” or “notdrop”.

Re:Rust in the Android Platform by nl on Wednesday April 07, 2021 @03:11AM (#26721358)
Google was bribed by JetBraine to adopt it

It's hard not being sarcastic in reply to this. But no, this did not happen.