Opposition to Python type hints
Opposition to Python type hints
Posted May 7, 2015 16:51 UTC (Thu) by niner (guest, #26151)In reply to: Opposition to Python type hints by ibukanov
Parent article: Opposition to Python type hints
Perl 6 throws errors for invalid method names if possible at compile time. I.e. when it knows about the types involved and no fallbacks are present. It's also very helpfully complaining about invalid arguments to methods and functions. And its type system allows very fine grained specification of types and signatures. E.g. it allows one to declare a function that takes a hash (dict in Python) as argument and requires that this hash contains certain keys. So in essence, it makes a combination of duck typing and static types possible and useful.
