Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Python is the most incredible language because everything's dynamic. But it comes at an enormous cost - you can't make many assumptions or optimizations easily. It has tremendous utility for many applications. It's this utility and the wide body of existing software packages which makes it so tempting to use as a scripting engine. But it would be a bad move for any scripting that's in some critical region.


It would be nice to have an official, more performant statically typed/less dynamic subset of Python.

Yeah we have mypy, but its not official and not integrated. And subsets that do have a performance benefit (like TorchScript) are niche and/or not sustainably supported.


Not statically typed, but rpython is a statically analyzable subset of python that is used to write pypy: https://rpython.readthedocs.io/en/latest/rpython.html


That looks very reasonable. Converting a Python codebase would be much easier than porting to a new language.

Now all your imports, on the other hand...


Well -- other languages have shown up to try and fill this niche.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: