4 ms·
Obviously, these things are subjective, but... Python? Haskell? Scala? Heck, even modern Java?
by Quekid5 6y ago
Obviously, these things are subjective, but... Python? Haskell? Scala? Heck, even modern Java?
- unnouinceput 6y agoJava elegant? Where you actually have the need for an IDE to be on a ultra-wide monitor because otherwise you can't read the name of a class? And you call that elegant? Python elegant? Probably you meant easy to learn, but elegant is something else entirely. Not to mention is still interpreted (though for the life of me I can't phantom why none writes a compiler for it. Would be a huge advantage) Haskell is the only one that I would call elegant on this list. But we were talking about modern. Haskell is 30 years old, I would not call that modern. Also Haskel and Lisp can be written (just like C macros if you want) to birth an entire different syntax if that's your kink.
- Quekid5 6y agoMaybe this would be easier if you shared your definition of 'elegant'. > Haskell is the only one that I would call elegant on this list. But we were talking about modern. Haskell is 30 years old, I would not call that modern. Also Haskel and Lisp can be written (just like C macros if you want) to birth an entire different syntax if that's your kink. The only mention of 'modern' in this thread was with respect to Java... you know, the one with record types which eliminate a lot of boilerplate? I'm not sure why age should count against Haskell, when you agree that it is 'elegant'? I should point out that the Haskell of 30 years ago is very different from Haskell today. I'm not even sure what we're arguing about at this point.
- kevin_thibedeau 6y ago> or the life of me I can't phantom why none writes a compiler for it. Would be a huge advantage Pick your poison: PyPy https://www.pypy.org https://www.pypy.org Cython https://cython.org https://cython.org Nuitka https://nuitka.net https://nuitka.net
- unnouinceput 6y agoI have a problem. For some reason a good mathematician wrote the solution to it in Python. Works great. Now I want to use that solution, which is very complex, tens on thousands of lines in Python, in another language because I also need speed and Python is solving that solution in too much time. What choices do I have? One would be to rewrite the solution myself using provided Python code as base. Second would be to get the Python code compiled in a .dll(Win)/.so(Lin) and use it. Can above poisons do that for me? Answer: NO. I tried all 3 already, they do. not. work. Otherwise I can definitely call Powerpoint2Exe an interpreted language too since it can generate a standalone executable.
- ptx 6y agoStatically compiling general Python code to a high-performance standalone executable is currently not possible. But to solve the problem you describe, you can: 1) embed CPython in your app to run the Python code (i.e. link with the libpython DLL), and then 2) modify the most performance-critical parts of the Python code so that they can be compiled with Cython or mypyc (or write them in C using the Python C API).
- pjmlp 6y agoAll workarounds for something not needed to do had the OP started with a language with proper AOT support.
- mypalmike 6y ago> I can't phantom why none writes a compiler for it. Would be a huge advantage When every variable and field access involves a hash table lookup, the interpreter loop is not the primary performance bottleneck.