|
|
|
|
|
by hota_mazi
2334 days ago
|
|
Yes, the general idea is not new but the devil is in the details. As far as I can tell, Odin's `using` is applicable in the same areas as Kotlin's, but I still favor Kotlin's scoped version. When I see "using foo;" in Odin, it's not quite obvious to me where the scope of applicability is. Any reason why you didn't do something like entity.use {
// "this" is now the entity instance
}
// back to your regular "this"
?
|
|
Koltin's approach is limited to purely the same Pascal's `with` allowed.
But if you want to be clear: