3 ms·
> they're checked at run-time but not compile-time Do they intend to add this? I think it would make a big difference. It would make thje language more like Ha
by cabalamat 5y ago
> they're checked at run-time but not compile-time
Do they intend to add this? I think it would make a big difference. It would make thje language more like Haskell, where lots of bugs would be caught at compile time.
> it only checks the top-level type. E.g. `List<Number>` just checks that it's a list.
That's fair enough because otherwise it might have to go though potentially very big data structures.
Maybe there could be a command `strict_check(aDataStructure)` which would only get executed when type checking is on and would recurse into a data structure checking everything.
- scns 5y agoIt is used to to teach children. Spoken the name sounds like pirate. No snark intended.
- cabalamat 5y agoI'm not sure if this was intended as a reply to my comment. In any case, I would suggest that a language be powerful and simple enough that it can do a wide range of tasks including teaching children, GUI apps, web apps, AI research, scripting, etc. Python does this and Pyret should aspire to do it too.
- scns 5y agoIt totally was. Type checking is being worked on, they were not happy with the performance of their first implementation.