3 ms·
> "In general, types really just get in the way when scripting or prototyping or trying to do anything fast" I've found the opposite of that claim to be true.
by xearl 10y ago
> "In general, types really just get in the way when scripting or prototyping or trying to do anything fast"
I've found the opposite of that claim to be true. Types are absurdly helpful in prototyping or trying to do anything fast, especially when exploring data coming from a file or an external API.
Anecdotes aside, BinTree in the example is both a data type and a type testing function ("detector") of signature `Any -> Bool`. See http://www.pyret.org/docs/latest/Declarations.html#%28part._s~3adata-decl%29 http://www.pyret.org/docs/latest/Declarations.html#%28part._... for details.
- AstralStorm 10y agoTypes are great unless you are forced to be explicit instead of the compiler doing automated type deduction.