Even regular Rust code is more “exciting” than Python in this regard, since you have a choice between self, &self, and &mutself. And occasionally mutself, &'aself, and even self: Box<Self>. All of which offer different semantics depending on what exactly you’re trying to do.
I’ll add that 100% of the above is understood by the compiler. Unlike Python or JavaScript where you don’t know how bad you have it until the program is already running.
Even regular Rust code is more “exciting” than Python in this regard, since you have a choice between
self
,&self
, and&mut self
. And occasionallymut self
,&'a self
, and evenself: Box<Self>
. All of which offer different semantics depending on what exactly you’re trying to do.I’ll add that 100% of the above is understood by the compiler. Unlike Python or JavaScript where you don’t know how bad you have it until the program is already running.
At least python has a decent runtime typing system
JS’s type system feels like what you’d get by giving a monkey access to unlimited cocaine and a computer