2 ms·
Upthread was: > If Rust follows Scala then `()` is not the empty tuple, but rather Unit (void in C*). The implication is that () == Unit == void. The empty tu
by vertex-four 10y ago
Upthread was:
> If Rust follows Scala then `()` is not the empty tuple, but rather Unit (void in C*).
The implication is that () == Unit == void. The empty tuple and unit are essentially equivalent aside from name, void is something else.
- dllthomas 10y agoRegardless of who is right, you are arguing the wrong bit of it. I contend that, to a person, everyone saying "C void is Unit" doesn't think C void is Void. Arguing that Void is not Unit is just completely spurious. Of course Void is not Unit. No one disagrees. In truth, C void is not exactly either Void or Unit. Like Void, you can't exactly make one... but you can call functions declared to take it and write functions that return it, and really it just means "I have no information to pass" - which is more like Unit.