Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
uryga
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
21 ms
·
151.
▲
by
uryga
6y ago
recent thing with github and renaming "master"
152.
▲
by
uryga
6y ago
i didn't downvote you, but since you're asking – the first part of your comment is needlessly snarky and doesn't really add much beyond "yeah, i'm frustrated by people adding unnecessary complexity just because it&
153.
▲
by
uryga
6y ago
> Also, what stops something like [defining add as subtraction] cmon... "it doesn't guard you against every logic error under the sun" isn't a great argument
154.
▲
by
uryga
6y ago
i appreciate your concern :) but honestly, is that a practical problem, or a theoretical one? the end result was fine to watch in our case. (and upload itself wasn't of great quality anyway)
155.
▲
by
uryga
6y ago
> H.264 was supported everywhere this. our TV (a few years old, "smart") can play videos from a network drive, but doesn't support H.265. reencoding a season's worth of episodes to H.264 takes a while...
156.
▲
by
uryga
6y ago
> couldn't you fix this with dependent types somehow? quoting from the post: > the way I had set things up, every time I used the [sqrt] symbol I had to supply a proof that what I was taking the square root of was non-negative. &
157.
▲
by
uryga
6y ago
from my experience digging through Cython output: unless you type-annotate EVERYTHING C-style, Cython just uses the CPython C-API (PyObject_New, PY_INCREF, etc). so you'd have to ship all of CPython anyway... as mentioned elsewhere in
158.
▲
by
uryga
6y ago
i've heard a lot about SBCL and the efficient machine code it generates. i'm guessing a lot of the heap stuff can be optimized away if the code is written right (e.g. via escape analysis or eliminating intermediate values). though
159.
▲
by
uryga
6y ago
tbh... does that matter? until they ship no-reboot-updates, their (hypothetical) effort doesn't do much for me....
160.
▲
by
uryga
6y ago
it's a shame :( and honestly, i think the whole "if it needs statements, it should be a named function anyway" argument is misguided (and maybe kind of a post-hoc justification of the limitations of Python lambdas). introduci
161.
▲
by
uryga
6y ago
interesting! why not?
162.
▲
by
uryga
6y ago
> You would not get through code review with that in any shop that has discipline. ... and i'd never think to try! that's why i mentioned using it in a REPL and called it a hack :) it's just fun. i played around with bytec
163.
▲
by
uryga
6y ago
> Allow to inline them and you will see monsters in the wild. idk... you can write a huge ugly if-elif-else like this: a if foo else b if bar else c if quux else d but most people just don't.
164.
▲
by
uryga
6y ago
btw, my favorite FP-hack: let-in expressions with lambdas OR list comprehensions: let x = foo in expr can be [expr for x in (foo,)][0] (kinda reads like a Haskell `where` clause!) or: (lambda x = foo: expr)() useful in
165.
▲
by
uryga
6y ago
what do you think about if-expressions? x if cond else y IMO match-expressions have basically the same benefits/trade-offs.
166.
▲
by
uryga
6y ago
the Syntax section has a bit more: > "[...] making it an expression would be inconsistent with other syntactic choices in Python. All decision making logic is expressed almost exclusively in statements, so we decided to not deviate
167.
▲
by
uryga
6y ago
glad to see this! though it's a shame that the proposed `match/case` is a statement, not an expression: > "We propose the match syntax to be a statement, not an expression. Although in many languages it is an expression, b
168.
▲
by
uryga
6y ago
> What do you mean by a main-less script? probably something that's common in "scripting" languages, where you don't have to wrap your code in main(), it just executes from the top: myscript.py ----------- pri
169.
▲
by
uryga
6y ago
why is "@" so bad? i mean it's a huge glyph but it's just an operator like +-×÷•, you get used to it
170.
▲
by
uryga
6y ago
i'd love a group like that!
171.
▲
by
uryga
6y ago
[you're probably joking, but in case you're not...] people also pronounce "GAN" (Generative Adversarial Network) with a hard G even though Generative is a soft G (J). and how do you pronounce "MUA" (Mail User A
172.
▲
by
uryga
6y ago
> [Actix] is just one of the more notable times that something like that has happened. edited my comment to reflect this, thanks i was trying to keep my summary relatively opinion-free – the internet probably doesn't need my take on
173.
▲
by
uryga
6y ago
for anyone not following Rust, the drama around the (popular) Actix web framework was a prominent instance of this. iirc people opened issues and PRs re: the project's (significant) usage of `unsafe`, but the maintainer (Nikolay Kim) w
174.
▲
by
uryga
6y ago
> Go does not inline range operation. do you know why? [not super familiar with Go, just curious]
175.
▲
by
uryga
6y ago
would `become` be a good alternate name for it?
176.
▲
by
uryga
6y ago
are you arguing against keyword arguments in general, or against def foo(a, b, **kwargs): """ Refer to `bar` for the full list of allowed kwargs. """ ... i don't mind the former, bu
177.
▲
by
uryga
6y ago
re: "binary", i think the article just uses the term incorrectly – it's probably intended to mean "single file thing you invoke directly". i'm guessing they didn't just say "script" bc of possibl
178.
▲
by
uryga
6y ago
[not defending patent trolls, just poking what seems to be a hole in the concept] > Its okay if they are actually still in the process of building the thing what should happen with a patent holder who sells off their R&D department,
179.
▲
by
uryga
6y ago
i learned about OS/2 from the 'Doing Windows' series. really recommend it, it's a great read about the history behind all this stuff, the computing landscape of that period, and why OS/2 was a huge achievement. htt
180.
▲
by
uryga
6y ago
i understand the idea of proof-of-work. but idk, when i think about all that electricity and computing power wasted on guessing arbitrary numbers... just doesn't feel right kind of reminds me of how FAANG job interviews require memoriz
More ›