And may be a a road to gradual typing, i.e. a forward looking auto. The language spec will probably never allow if (maybe someday in C++), but IDEs might fill in the type for you if it can be deduced from a call site later on.
I find it really... Wonderful how types and declarations are inferred from actual code using 'em.
OTOH, this is something I see a lot in Hindley-Milner typed languages, although they don't usually go too far here, i.e. it's not like OCaml or Haskell generates a type declaration for me.
6 comments
[ 3.1 ms ] story [ 25.5 ms ] threadThey implemented a working demo, along with some helper code so they are trying to push it.
How about IDEs?
I find it really... Wonderful how types and declarations are inferred from actual code using 'em.
OTOH, this is something I see a lot in Hindley-Milner typed languages, although they don't usually go too far here, i.e. it's not like OCaml or Haskell generates a type declaration for me.
http://cnippet.cc/