Hacker Newsnew | past | comments | ask | show | jobs | submit | gfna's commentslogin

Well the article did mention it was in an undafe block


1) unsafe block still of "rust" code that rewritten in "rust" to be safe compared to previous C code. 2) Maybe there is no other way than use "unsafe" block sometimes in "rust", so is Rust a lie?


Rust constrains the code that can do unsafe things to small blocks, greatly reducing the area in which they can happen. Unlike C, where the whole of the code is unsafe.


I imagine for some very low level kernel stuff, you might want to turn off Rust's safety features because they get in the way, make things less efficient or something.

But then when you do you should really know what you're doing.

The fact that this bug is because of "unsafe" Rust usage actually affirms the language's safety when using "safe" code. Although with "memory safe" code you can of course still fuck up lots of other things.


Been using gitkraken for ages and still like it, but they do make it harder and harder to like every update. The enshittification seems to have started and every update seems to bring more and more ai features, and pushing more ”cloud” features as well


We did this in a project where, due to reasons, we used a windowless, dull, claustrophobic meeting room for 6 months. Every now and then our daily was interrupted by the sight of an elephant on the screen


Gpl and mit licenses dont have multiple parameters


c# has been my go to language for everything except frontends for the past 15 years, but there are still some things I really miss from Rust. The top one is probably pattern matching. Sure C# has something similar with switch expressions, but with them you must assign something, and they cannot contain code blocks. Related to this something like enum variants is also missing, and therefore making something similar to Result or Option is not really feasible without it being quite hacky. Also being able to create new types from existing ones with eg struct Years(i64); and pass it around typed is quite nice in Rust (F# has something similar, however there it will then always also be assignable to i64, so is not very helpful for catching incorrect usage.


I’d be eager to hear folks poke holes in this opinion, but it seems like C# has made a wild mess of class/record initialization in recent versions, whereas in Rust fields are either simply required or are optional.


Properties in C# follow a similar pattern. Constructors can have their own arguments which can also be mandatory or optional. In Rust this logic simply lives in a function instead.

The only issue in C# is that structs come with a. default parameterless constructor (which can be overridden) and b. can be default-intialized (default(T)) without the compiler complaining by default. These two aspects are not ideal and cannot be walked back as they were introduced in ancient times but are rarely an issue in practice (and you can further use an analyzer to disallow either).

F# is more strict about it however and does not have such gaps.


There’s also (in C#) init, readonly, required, and quite a few more keywords and techniques, governing property mutability, private class field mutability, and so on.

And then none of those techniques work as well as manually typing out a required constructor which hard-enforces that required data be priced upon object initialization.

I understand required vs optional immediately a la Rust and F# (ignoring for a moment F#’s null awareness) but as a 17 year C# dev, I’ve had to create an initialization chart to keep straight all of the C# techniques.


> Also being able to create new types from existing ones with eg struct Years(i64); and pass it around typed is quite nice in Rust (F# has something similar, however there it will then always also be assignable to i64, so is not very helpful for catching incorrect usage.

F# has units of measure which are quite a bit more powerful: https://learn.microsoft.com/en-us/dotnet/fsharp/language-ref...


I would also like to see a study which considers the age of the pecorino. I seem to have an easier time of getting the proper emulsion with older drier pecorino, and less risk of clumping


Costco peccorino works well.


Whole Foods has superior quality pecorino, the one with the black crust.

The last 10% quality improvement is the hardest to achieve without good ingredients, even if you can make it work otherwise.


Didnt recogize the english title before i read this comment and it immediately clicked. The copy i have is from the late 80s and even then it was a bit dated, but it didnt matter. Awesome book. Now 35 years later my kids and I sometimes spend hours looking through the same book. Even more dated now, but that probably makes it even more amazing for them and now they know how a tape recorder works \o/


theres an updated edition as well


Until gps fails and it starts repeatedly braking because it thinks it is somewhere else


It doesn't brake for you, not even in the most hardcore version of this law proposed by the EU.


For now.


Well this is going to be interesting if they rely on GPS. Possibly due to gps jamming by our neighbour country i have had to disable the feature where the car tries to predict the road ahead and suddenly brakes on the motorway because it thinks it is on a side road 10s of kilometers away.


Ford even did an ad campaign around this concept some years ago https://media.ford.com/content/fordmedia/fna/us/en/news/2017...


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: