top | item 43693796

(no title)

kelafoja | 10 months ago

I agree, there are only superficial similarities. Like they're all 3 C-based. And Go and Rust both compile to machine code. I believe once one of the creators of Go mentioned that it felt to some users "like a faster Python". But I have no clue how Python relates to Rust in any sense, I fail to see any similarities. In fact, I would almost be inclined to say that Python and Rust have more differences than similarities.

discuss

order

woadwarrior01|10 months ago

> I would almost be inclined to say that Python and Rust have more differences than similarities.

This is somewhat of a stretch: dyn Traits in Rust are sort of like compile time duck typing. OTOH, interfaces in Go and virtual functions in C++ are the same thing.

steveklabnik|10 months ago

It really depends on what kind of axis you’re talking about. Under the hood, Go’s interfaces and Rust’s “dyn types” (the new nomenclature for trait objects) are the same, and C++’s virtual functions are different.

(Though you can emulate them with unsafe in Rust, like anyhow)