IIUC that was meant as an intermediate step (which isn't uncommon), which IMO makes the translation way less exciting.
The interesting part will be whether they can transform that "mechanical Rust" into something idiomatic. I'm waiting ...
HN user
IIUC that was meant as an intermediate step (which isn't uncommon), which IMO makes the translation way less exciting.
The interesting part will be whether they can transform that "mechanical Rust" into something idiomatic. I'm waiting ...
In my experience, it absolutely does (at least if you use it idiomatically). Using the type system (esp. enums, Result and newtypes) makes a good bunch of invalid states irrepresentable.
This also helps to focus on the remaining things that could go wrong.
The integration of unit tests also lowers the barrier to just sprinkle some tests in, if you're unsure that you got an edge case right. Anf clippy (not stricly the language, but still kind of a core component) greaty helps to stay on the idiomatic track.
No silver bullet of course, but I never had so few runtime issues with any other programming language so far.
What logic bugs did you encounter the most?
edit: mobile typos
I had no troubles targeting an ATTiny13A with Rust.
(had to disable debug symbols, though)
Why should that be any harder than C?
IIUC only 50k LoC are non-test code, which improves the metric. Whether that's enough tests still depends on the code. If most are getters and setters, the coverage might be ok.
I often wish this type existed, but didn't find a way to define the niche value for the compiler to optimize the None-case.
Do you know a solution to this?
Support for Firefox on Linux is still only in nightly (unless that changed "very" recently)
This blocks progress (and motivation) on some of my projects.
In your specific example `std::convert::Infallible` can be used: https://doc.rust-lang.org/std/convert/enum.Infallible.html
LineageOS was just the easiest for me personally (was already installed anyway). But aren't there parental tools to lock down phones for non-tech people?
Another middle ground would be to insert no SIM card (my kids only had access via WiFi at first) or to disable mobile data.
Maybe my kids are special, but so far it was enough agree upon rules about what they are allowed to do. As soon as they break the rules they will loose some of their benefits. No rule works for everyone, but simple "no" to a technology that has so many upsides for our family life is also nothing for me.
Edit: also "selling a locked-down phone" is exactly NOT a solution. Parents will have to learn the up and downs of this technology and apply an individual solution to their situation.
Initial results from a groundbreaking study by the National Institute of Health reveal that MRI's found significant differences in the brains of children who use smartphones, tablets, and video games more than seven hours a day.
Reminds me of "Every single person who confuses correlation and causation ends up dying".
Jokes aside: "more than 7 hours a day" is a _quite little more_ than the 0 hours the site is asking for. Also I'd guess it might make a difference whether the kids are using a drawing app, tiktok, learning a foreign language, reading an eBook, playing a shooter, gambling, …
Who will teach them how to (not) use them once they have one? I mean things like privacy, phishing, social media risks, addiction, subscription fees, etc.?
I think the possession of a device isn't the risk itself.
So, no flexibility, spontaneity? So far we had:
- "I'd like to stay with a friend after school - they'll drive me home after dinner", "Sure, thanks for the info, have fun"
- "Fire alert, I'm fine but bored"
- "Had to help a friend with an accident, will be home 1h later approx"
- Bus didn't turn up, uses app to improvise an alternative connection
- asking teachers about details from the lessons
- getting a news-feed from school
- looking up the schedule if things change
- manage their calendar and todo-lists
- set an alarm/reminder
So basically "everything" an adult does with their phone to make their lives easier.
After that there's enough brain left to learn that social media is something that needs special attention
I had the same sentiment when reading.
It all looks like B'n'W opinions and mixing devices and services. I completely miss the "parenting" aspect. It's all about prohibition.
I wholeheartedly agree.
I think it's more important to talk about the services they use than what device they're on.
And most problematic services already have an age limit. It's the parents' damn job to make sure their kids are prepared for the usage of those services.
I'm more worried about the youtube-consumption on the PC than chatting with class-mates about school-related questions via smartphone.
Let’s protect the elementary and middle school years from the distractions and the dangers of a smartphone.
… because of unrealistic social pressure and expectations to have one.
Sorry, but I do not agree with the equivalence of a device and one of its possible usages.
My kids got their first smartphone at the ages of 5-6. (dramatic pause)
When I was younger me and my siblings got a camera, a Game Boy, a watch, a walkman, a calculator, a stopwatch and small handheld battery-driven games. Later a tamagotchi and whatever was trending. Also we were taught to use the phone-booth in case of an "emergency". While you do not have to agree that all of us needed all of this, nobody would've said to "wait until the age of 13" with all of this.
The phone I gave my kids were retired Android smartphones with Lineage OS installed. Almost all Google Apps removed or disarmed. I preinstalled Apps like: a calculator, camera, a secure messenger (Threema), clock, navigation (OSMAnd), a few educational games, a paint/drawing app, a calendar and added the most important contacts (Parents, siblings, grandparents) to the address book. We added more apps over time when we felt they might benefit from them.
We agreed upon usage duration and modalities. We mostly moved their TV-time towards their phones. We explained how to ask before taking a photo of a person.
What happened? My Kids started to get interested in how to read/write, used the navigation software during road-trips to find the next possible stop to have a break or try to find POIs along the road and wait them to pass by. They played with the calculator, started to learn English (non-native if that wasn't obvious, yet), started to "program" robots, send me "good nights" when I was late at work. Call me if they spontaneously decided to stay with a friend after school. Take photos during their holidays, listen to audiobooks during road-trips. Play with the torchlight in the tent.
The older one is now 12. She got access to our family calender and contact list, so she can plan her appointments with friends around ours, manage her ToDo-lists, make stop-motion videos, research all sorts of stuff on wikipedia, gain a very good understanding of how those devices work. Learn to take care of expensive gears and how it matters to have control over their own data and that backups are important. She learns how to manage her data plan by moving audiobooks for offline-usage. Also she helps her grandparents with all sorts of technical problems they have with their phones.
Yes, it's more work to teach a kid how to work with all this stuff than just throw an iPhone at them when they turn 13 and say "whoa, finally old enough to figure this all out." What could go wrong. Sorry, that I'm a bit salty on this topic (and I sometimes might not find the right words due to the language barrier), but just saying that a smartphone is bad because parents do not care for what their kids are doing with the device just feels plain wrong to me.
At least everyone who's stuck with Windows and AAA-gaming. But we'll see for how long.
However, this solution is not very ergonomic, as it requires the user of the function to first check if the returned value is Some(iterator) and only then iterate over the iterator.
I'd use `flatten()` to iterate over this nested type.
I really wish that I could pay for an ad-free service, without being tracked on every site there is :(
Just offer a plain youtube-Account and we have a deal.
Our kids at school are using https://cscircles.cemc.uwaterloo.ca/ for an introduction to Python and it seems they're making good progress (age 11 to 14)
It's available in German (and maybe other languages), too.
Ah, yes. Should have been more specific: NXT and EV3
I'm still mad that they discontinued Mindstorms. My school isn't able to replace their components if they break and I cannot get additional motors for my projects any more.
Does anyone know how good their "LEGO® Education SPIKE™" stuff is? Is it as open as the NXT-bricks? Are these somewhat compatible? Linux IDE available?
I wish someone would offer a replacement for those who have a 3D-printer, rp2040 and some soldering experience. I'd help the school to re-stock their supply.
Edit: 35 € for a 2 A USB power supply is definitely Apple-ish. And those peripheral connectors look like they're … unique. Mindstorms just had standard RJ-something plugs.
Funny coincidence. I found Dracula for VSStudio two days ago. So far it is the only dark theme that provides overall readable texts combined with red-shift for me.
Single-line comments could be a bit brighter, though.
you can swipe the address bar to switch between tabs. Better than nothing.
I like my Fairphone, but it's certainly not everyone's choice.
That's the second time on HN where I thought some article was about the window-system :(
Germany is filling the gap by importing electricity from France
Not to disagree, but the picture is more complex.
https://www.reuters.com/business/energy/even-crisis-germany-...
Maybe ask France or the US, they seem to be more practical on how to do this
Was curious about that as well, but I only keep finding "solutions" that are in the make or disputed.
This is from 2014, so maybe they found a solution in the meantime? https://www.bbc.com/news/science-environment-26425674
I'm also trying to find the final costs of any disposal.
Renewables aren't without problems of course. We still need a solution where the blades of the wind turbines don't end up in landfills. That's effectively not renewable.
And PV panels don't? You need many less trucks of uranium than of coal
I don't understand. Coal isn't required to build PV? We once had PV industry here but everything moved to $China :(
I know. But this doesn't sound too healthy neither https://pubmed.ncbi.nlm.nih.gov/11900206/
Not sure why everyone assumes I'm pro coal when I explicitly stated that I'm trying to push renewables.
I never suggested that "my personal solution" is to be applied everywhere. I suggested to work on making renewables more approachable and to reduce the energy consumption where it's feasible.
Not sure why I'm being personally attacked like this.
Then, I'm one of them.
I own a PV covering 120 % of my yearly power consumption. I obtain the remaining (night-time) energy from a 100 % renewable provider (no nuclear). I rarely use my car, which only consumes 5 l / 100 km. Most is done via bike. I work from home, use a Fairphone and teach my kids to produce less waste and try to repair everything that breaks.
I'd rather invest my money into developing seasonal power storage than building another nuclear plant.
France is already overheating their rivers and Germany has to fill the gap, whenever they have to shut down too many their plants. In Germany we still have to figure out how to get rid of the existing nuclear waste (and fix the previously failed attempts). Uranium has to be imported from other countries. Fukushima and Chernobyl are still not cleaned up. Even regular plants take decades to be decommissioned. We still cannot eat Mushrooms and Boar from Bavarian forests due to Chernobyl.
I know that being anti-nuclear is an unpopular opinion on HN, but that's how I think about that.
Not sure if that counts, but I successfully wrote Rust programs for several embedded systems and microcontollers.
The smallest one was an ATTiny 13A (64 bytes of RAM).
I'm still trying to get MythBusters and DuckTales* in German. I can only find fragments on youtube and some shady websites.
I'm totally willing to pay full price, but there's simply no offer.
Edit: I just learned about justwatch.com (thanks HN!) There's one streaming service listed which offers at least two seasons for 7 € per month - including commercials :/ it became so hard to buy stuff legally.
* the available DVD are incomplete. I could fill some gaps in English.
It's 25 bits if you take the sign bit into account.