Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
joejev
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
9 ms
·
31.
▲
by
joejev
9y ago
The reason the syntax was rejected is that you can implement the exact same feature without special syntax. You could write: nt(a=1, b=2) and dynamically create a struct to store the data. In 3.6 this even preserves the order of the keyword
32.
▲
by
joejev
9y ago
One advantage of namedtuple is that it is just a tuple! You can pass the namedtuple to code that expects a tuple, even C code that expects a tuple. This makes it easy to add names to tuples after the fact without breaking existing code. In
33.
▲
by
joejev
9y ago
Destiny did this with just queens and drones. A lot of games were insane creep spread and spine crawler pushes.
34.
▲
by
joejev
9y ago
Python lambdas are just syntactic sugar for creating a function object. The ast can just build a named function and use it in the needed expression.
35.
▲
by
joejev
9y ago
C uses {} for arrays and this is written in C.
36.
▲
by
joejev
9y ago
Why was there so much Japanese traffic on the old nyaa.se (now nyaa.pantsu.cat)? Most of the raws are uploaded from Japan.
37.
▲
by
joejev
9y ago
https://www.continuum.io/blog/news/continuum-wins-darpa-xdat... It was blaze and bokeh. The description of blaze given in the article is pretty out of date at this point.
38.
▲
by
joejev
9y ago
It is the other way around: just because the source is available free of charge does not make the software free as in freedom. For example, there are licenses that prohibit you from running the software for commercial use even though you ha
39.
▲
by
joejev
10y ago
> - performance is important in much of the project At scale this always becomes true. C++ can be written with reference counting and other high level concepts with runtime penalties. When you need to optimize or scale, you will never ne
40.
▲
by
joejev
10y ago
> but there's a reason why GOTO is considered to be brain cancer and pattern matching is generally considered to be great. Look at any large C codebase and you will see plenty of goto statements to manage resource cleanup. The probl
41.
▲
by
joejev
10y ago
I don't think that it will ever work on PyPy. The data stored in the `co_code` field is a super set of the instructions python understands. The `co_code` data starts with a prelude which is the repl and builtin words, then there is a l
42.
▲
Show HN: Phorth – A Forth-like language on the Python VM
(github.com)
62 points
by
joejev
10y ago
|
14 comments
43.
▲
by
joejev
10y ago
I hear this complaint about print all the time but I have never understood it. Why is print so special that it needs dedicated synta? Most languages don't do this and people don't seem to mind. Also, I almost never physically type
44.
▲
by
joejev
10y ago
Why not send requests out of the blue? This happens to me all the time and I don't mind. It means someone cares enough to try to fix their problems instead of dumping it on me.
45.
▲
by
joejev
10y ago
timeit does a run to decide how many loops to do, since it was much faster it ran it more times.
46.
▲
by
joejev
10y ago
Hey, cool site. I work a lot with financial data and decided to poke at this, here are some thoughts / findings: - It would be nice to be able to look up companies by CIK instead of just ticker. - You should support share class delimit
47.
▲
by
joejev
10y ago
What is a security vulnerability in a library here? Do you mean something like using `numpy.frombuffer` to mutate strings in place, or using `numpy.lib.stride_tricks` to access invalid addresses? Maybe this is something like functions calls
48.
▲
by
joejev
10y ago
What does vulnerable mean in this context? Methods which forward input in a way that unlocks arbitrary code execution?
49.
▲
by
joejev
10y ago
PyPy is still not really a performance option for numerical computing.
50.
▲
by
joejev
10y ago
It is a little disingenuous to say that zipline doesn't support python, the short description from github says: "Zipline, a Pythonic Algorithmic Trading Library". Zipline also supports equities at minute and daily frequencies
51.
▲
by
joejev
10y ago
At first glance you would think that python would be slower than C#; however, all of the real computation is happening in Numpy (C), Pandas (Cython which compiles to C), or in our own Cython. The extra overhead of the python is mainly domin
52.
▲
by
joejev
10y ago
Could you explain why you feel that it is better? What in particular does LEAN support that Zipline does not support?
53.
▲
Show HN: Algebraic data types and pattern matching in Python
(github.com)
1 points
by
joejev
10y ago
|
0 comments
54.
▲
by
joejev
10y ago
Too bad no one can deploy linux servers because of all the segfaults.
55.
▲
by
joejev
10y ago
pypy only does python 2. Some people want to use the new features of python.
56.
▲
by
joejev
10y ago
so in this language these all do the same thing: abc "abc" abc, "abc", How does increasing the scope simplify things? Defining correct as "crashing less often" is a really bad idea, data formats _should_ be str
57.
▲
by
joejev
11y ago
Not all startups are like this, the author is bitter about his experience.
58.
▲
by
joejev
11y ago
It is a bit ironic that these "gnu" core utils are not licensed under the GPL
59.
▲
by
joejev
11y ago
The .pth imports a file which at module scope registers a search function with the codec system. This function checks if the name is 'quasiquotes', if not, return None otherwise return a custom object that defines all the methods
60.
▲
by
joejev
11y ago
I think some of this might be addressed in the implementation section of the docs. http://quasiquotes.readthedocs.org/en/latest/impl.html To summarize: there is no import hook or ast parsing happening. Instead, th
More ›