Open
Description
I haven't fully thought this through yet, but what if we had the ability to overload ()
for a derived type in various contexts? That could be used for some interesting things.
Such as dictionaries:
type(dict) :: d
d('key') = 1
d(1995) = 'string'
or a string class:
type(string) :: s
s = 'hello world'
write(*,*) s(1:5) ! this writes 'hello'