4 ms·
“Where could I find” is indeed an important question, but it is not obvious to me that hierarchical namespaces are the best solution. Couldn’t something like a
by Oreb 7y ago
“Where could I find” is indeed an important question, but it is not obvious to me that hierarchical namespaces are the best solution. Couldn’t something like a list of tags attached to every function/type/whatever be at least as effective?
- alexisread 7y agoI think the end result of something like this is call-by-meaning. Alan Kay and co. Have published several papers on this subject, but in a nutshell the code looks for a matching function to a signature and return type, then calls it. Obv. There are issues with this approach if fully automatic (how many sum functions take two ints and return int?) but there's no reason why we can't use a sig/return to filter on ie. The same function can be in 2 modules if filtering by sig or by return type. With typing similar to Haskell we can be even more strict - the sig/return is a contract, and we can have multiple types like userInputInt, randomInt which can differentiate similar inputs. With good typing and behavioural provability we may be able to move towards a call-by-meaning system