HN user

nicklauri

37 karma
Posts0
Comments9
View on HN
No posts found.

Yes, they're programs from the benchmarks game that use a lot of UnsafeMutablePointer, which is: > provides no automated memory management or alignment guarantees. You are responsible for handling the life cycle of any memory you work with through unsafe pointers to avoid leaks or undefined behavior. [1]

So I think they're "performance oriented Swift code". I'm not familiar with Swift, so sorry if I'm wrong. [1]: https://developer.apple.com/documentation/swift/unsafemutabl...

I'm pretty sure you're wrong like the way you're sure that you're right. Can you elaborate on why someone can't even go past a "Hello World" project would care about a feature that "other languages" have had it in years? I don't get it, I think they maybe hate Rust and should go throwing shade the language and ruin other people's feelings instead.

I would love to see that too, but I think that's likely never happened. Because Rust is kinda hard and takes quite amount of time and money to train new people, add more stacks on maintaining projects, and important thing is that I don't see why they have to use Rust. Go is good enough and they can work around with Go's disavantages.

Obviously, because the PHP regex engine is written in C, not in PHP. It's more like Rust's regex crate vs C PCRE rather than PHP, or who calls system call faster. While Rust's IO is locked[1] and doesn't buffer (which is slower than buffered, unsynchronized IO like other languages). And regex crate is slow when capturing, which is used on the "benchmark".

Reference: https://www.reddit.com/r/rust/comments/5zit0e/regex_captures... 2 years ago, but it's still valid to me, I've just tested it and it's much slower as I expected. Feel free to correct me if I'm wrong :)

[1] https://doc.rust-lang.org/std/io/fn.stdout.html