4 ms·
The names are just pointers, and they're both pointing to the same definition in your example. But when you redefine one of those, you would point one of the na
by sgk284 5y ago
The names are just pointers, and they're both pointing to the same definition in your example. But when you redefine one of those, you would point one of the names to a new definition.
It's similar to how DNS can have two domains point to the same IP, but then you can change one of those domains point to a new IP.
- ajuc 5y ago> The names are just pointers, and they're both pointing to the same definition in your example. But when you redefine one of those, you would point one of the names to a new definition. But how do you know which name was called where if the callers referenced the content hash not the name?
- aparsons 5y agoWould it not be correct for those callers to keep calling the old (shared) implementation?
- ajuc 5y agowell it would be nice to have a way to update old code
- milansuk 5y agoI also think that the DNS analogy is wrong because all callers are hash-based. The only solution I see is to go through the list of all callers and manually update selected ones. If I understand Unison right, the names are used only on the developer's layer(to write code), but when you save code, it's all hash-based. Still, Unison got my attention.