Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
adsharma
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
18 ms
·
301.
▲
by
adsharma
5y ago
You forgot bongoDB
302.
▲
by
adsharma
5y ago
It may not be a bad candidate for writing the rust part in python and then running it through py2many to generate the rust.
303.
▲
by
adsharma
5y ago
The idea that py2many is pursuing is to avoid having to deal with two languages and interfacing via python C-API. In other words you write your C++ or Rust with the python syntax, fixed width, signed/unsigned integer types and static t
304.
▲
by
adsharma
5y ago
I've been having fun transpiling python floats into rust f64 and c++ double last few months. Sometimes the rust way of doing things is very detail oriented and breaks the smooth flow of thought to code that python enables. Probably bes
305.
▲
by
adsharma
5y ago
The next cool thing is not "run python and 30 other languages online". It'll be write python, translate to other languages and then run them online. We're at 7. https://github.com/adsharma/py2many&#x
306.
▲
by
adsharma
5y ago
https://en.arguman.org/object-oriented-programming-is-a-tril...
307.
▲
by
adsharma
5y ago
Python has a PR problem: * That it's a dynamically typed language * That it's not a serious language like C or C++, suitable for writing a 50 line throwaway script I'd like to convince people that both statements are false. B
308.
▲
by
adsharma
5y ago
The transpiler could in theory generate code in the native language. You can see for yourself: https://news.ycombinator.com/item?id=27032399 Please file bugs/issues if something isn't working.
309.
▲
by
adsharma
5y ago
People write raft papers with pseudo code or some hard to comprehend systems language. I've always wondered why there isn't a Jepsen tested python implementation with lots of github stars. Here is mine: https://github.c
310.
▲
by
adsharma
5y ago
I wrote a python to rust transpiler (py2many) also as a fun project. I won't be surprised if writing a db in python actually becomes viable some years down the road due to the awesome tooling and the idea -> code uninterrupted flow
311.
▲
by
adsharma
5y ago
For me the issue manifested as a 10 sec latency to format a Julia file using Format.jl Solved via flags to disable JIT and brought it down to a couple of secs. Native binary would be much nicer.
312.
▲
by
adsharma
5y ago
If you have python code and trying to generate equivalent rust for performance, please give py2many a try. Looking for feedback. Also experimental support for pyo3 extensions. But really the main idea of the project is static python and com
313.
▲
by
adsharma
5y ago
I think there are a number of messages here: * Java is slowing our tools down * amalgamation sqlite style is showing the benefits of tightly written, standalone good old C. * By extension: monorepos are introducing complexity, since
314.
▲
by
adsharma
5y ago
https://github.com/adsharma/py2many/issues/229
315.
▲
by
adsharma
5y ago
If you prefer python syntax, you can code in python and transpile? Py2many supports nim. I wonder if there is sufficient interest in having a python stdlib compatible library for nim.
316.
▲
by
adsharma
5y ago
@fdej: what successor to ctypes did you have in mind? Other than the names (I prefer i8 over c_int8, but easy to work around) and lack of ergonomic interop with python ints, are there other issues you're aware of?
317.
▲
by
adsharma
5y ago
There is now a pull request for this: https://github.com/adsharma/py2many/issues/62
318.
▲
by
adsharma
5y ago
Please take a look at py2many which does this. Looking for feedback.
319.
▲
by
adsharma
5y ago
The distribution of popularity of the features is not uniform. My intention is to carefully look at the intersection of relatively less used features and features that make python slow/inefficient and exclude them from the supported su
320.
▲
by
adsharma
5y ago
Great. Thank you. I'll remove the "is" operator from the supported subset and perhaps rewrite the commonly used "a is None" to idiomatic code in the target language.
321.
▲
by
adsharma
5y ago
Aggressive type coercions in js frequently comes up 16 == [16] true in js false in python
322.
▲
by
adsharma
5y ago
I'm looking into a python -> dart -> js approach. Emphasis on static type checking and small feature set that's easy to understand. https://github.com/adsharma/py2many/ Made a new release earlier t
323.
▲
by
adsharma
5y ago
Is dart your preferred alternative?
324.
▲
by
adsharma
5y ago
python has a lot of features. But people use a small subset of it. So instead of supporting all of python, why not stick to the small subset that people actually want to use to solve a problem?
325.
▲
by
adsharma
5y ago
Why not transpile python to JS instead of running an interpreter?
326.
▲
by
adsharma
5y ago
There was a i32 -> f64 type cast problem fixed by this PR https://github.com/adsharma/py2many/pull/204 Also added this benchmark as a test case, so we don't regress.
327.
▲
by
adsharma
5y ago
Thanks for the link. I'm thinking along the same lines and might derive some inspiration from Haxe on how to evolve python syntax to support features like GADT and FP that can be easily transpiled to other languages. It looks like Haxe
328.
▲
by
adsharma
5y ago
Thanks for the link. I wasn't aware of mys. The project I'm working on is called py2many https://news.ycombinator.com/item?id=27032399
329.
▲
by
adsharma
5y ago
Python's pattern matching is not the same as Ocaml's. It's a statement, not an expression. But I like your line of thinking. Create a variant of python with ML like features without sacrificing compatibility too much. An effo
330.
▲
by
adsharma
5y ago
py2many: https://news.ycombinator.com/item?id=27032399
More ›