3 ms·
I'm envisioning a programming language in which variable names and type names can become one. So instead of func call(Person person){} you just have func call
by singularity2001 6y ago
I'm envisioning a programming language in which variable names and type names can become one.
So instead of
func call(Person person){} you just have
func call(person){}
where person is a known type AND the variable name.
In that scenario 'accuracy' would be a type with known value between 0 and 1.
- elcomet 6y agowhat if you have to deal with two persons?
- singularity2001 6y agoIn that case you could have the signature func call(person#1 person#2){}
- ajuc 6y agoWouldn't it be better if we could give meaningful names instead of 1 and 2? function call(person#sender person#receiver) And at that point we're back to the square one, just remove the # :)
- quickthrower2 6y agoCombine with the JS/TS syntax sugar for objects and {person} Is an object person with key person and value person of type Person