Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
pubby
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
27 ms
·
271.
▲
by
pubby
8y ago
IIRC, semilattices in type systems usually means subtypes, and lattices in type systems usually means subtypes plus a bottom type.
272.
▲
by
pubby
8y ago
SCD carries a lot of psuedoscience baggage so I don't blame doctors for not heeding its advice. It does seem to have a positive effect though. Hopefully one day we'll figure out exactly why it works (and doesn't work).
273.
▲
by
pubby
8y ago
You could try writing a homebrew game for an old system. That's a pretty good way to learn things. Once you start on the emulator, the first thing you'll do is emulate the CPU, which can be done as a big switch statement inside of
274.
▲
by
pubby
8y ago
There's a glaring memory leak if the second new throws.
275.
▲
by
pubby
8y ago
>Does this mean that we have a sort of bloom filter-esque test for primality? This catches most non-primes ;) bool maybe_prime(x) { return x % 2 && x % 3 && x % 5 && x % 7; }
276.
▲
by
pubby
8y ago
Is it really worth blaming the tool? Has reimplementing make for the 50th time really improved things? The fact is, building software that requires 500 dependencies and 500 sub-steps and 500 configuration options is going to be complicated.
277.
▲
by
pubby
8y ago
Monads are regular code. They get evaluated lazily like regular code, because they are regular code. It's really hard to explain it further.
278.
▲
by
pubby
8y ago
libclang to the rescue! (which CPY doesn't use)
279.
▲
by
pubby
8y ago
Regarding calloc, the issue is this: - Since C++14, SIZE_MAX is the maximum size of any valid object; any object larger is ill-formed. - calloc(SIZE_MAX, SIZE_MAX) is an attempt at creating an invalid object of size SIZE_MAX^2. - Thus, call
280.
▲
by
pubby
8y ago
I'm not the author of the website, if that's what you're thinking.
281.
▲
by
pubby
8y ago
I tested it. It doesn't help on Clang.
282.
▲
by
pubby
8y ago
Take a look at the number of gay-male postings vs the number of lesbian-woman postings on casual hookup sites. Neither of these groups fall into "traditional gender roles", yet males still post significantly more.
283.
▲
by
pubby
9y ago
I was not very specific. What I meant to get at was that if your bottleneck is memory, then optimizing for instructions is not going to help. is_sort is an example algorithm that's far more dependent on memory than it is on instruction
284.
▲
by
pubby
9y ago
Unfortunately SSE doesn't speed-up huge data much. It's only fast when everything's in the cache.
285.
▲
Show HN: The 2017 NESdev coding competition
(nesdevcompo.nintendoage.com)
2 points
by
pubby
9y ago
|
0 comments
286.
▲
by
pubby
9y ago
Nowdays, it's impossible to do modern programming without relying on millions of lines of other people's code. It's frameworks and libraries all the way down. On the NES however, every line of code is yours. There's no s
287.
▲
by
pubby
9y ago
I appreciate the effort, but as a C++ guy, code like this scares the hell out of me. Just a quick glance and I already have the impression that the code is full of memory leaks, UB, and bad code reuse. Plus, it has really bizarre stuff like
288.
▲
by
pubby
9y ago
I used to bash CICO as being an over-simplification until I actually looked at the numbers. The average american eats 3600 calories per day. Fat ones eat more; perhaps 4000 to 8000. This is far beyond amounts recommended to lose weight effe
289.
▲
by
pubby
9y ago
What do you do when you want to find the value a pointer points to? You dereference it of course! C++ and Java have their own specific language-lawyer definitions of the word reference, but outside of those languages, "reference"
290.
▲
by
pubby
9y ago
Top-down (descent) parsing gets a nice speed boost when you realize creating an AST isn't always necessary. Top-down parsing happens in the same traversal order as AST iteration, and this makes creating an AST not required. Bottoms-up
291.
▲
by
pubby
9y ago
Experts Exchange used to cost money to use. (a subscription)
292.
▲
by
pubby
9y ago
I recall being impressed the last few times I submitted bug reports to GCC. They were really on top of their game.
293.
▲
by
pubby
9y ago
There's the "BYOND engine". It started out as a scripting language for creating MUDs, but then grew to have 2d tile graphics.
294.
▲
by
pubby
9y ago
I think you're misunderstanding the point and confusing standards with documentation. Standards are for one very narrow group of people: compiler writers. If you're not a compiler writer, you have zero reason to buy the official s
295.
▲
by
pubby
9y ago
I always liked the story about the guy who aliased emacs to be 'em'. Until one day he accidentally typed an 'r' instead of an 'e'. It turns out aliases can cost a lot more time than they can save!
296.
▲
by
pubby
9y ago
The default nowadays is basic exception safety, where nothing leaks but objects can get put in invalid states. Strong exception safety (rollback semantics) is still pretty hard.
297.
▲
by
pubby
9y ago
The actual reason for 25 foot drops is probably to reduce both injury liability (spinning death blades) and the chance of drone theft/destruction.
298.
▲
by
pubby
9y ago
Wood houses don't get blown over or eaten by termites very often, but they do get torn down and rebuilt larger every ~50 years due to rising land prices.
299.
▲
by
pubby
9y ago
"Fall" has a few definitions but one of them is "pass into a specified state". So "fell asleep" means changing from being awake to sleeping. Apologies if you know this - I wasn't sure from your post.
300.
▲
by
pubby
9y ago
There's no operator because composition and direct sum are implicit in the order of your program words.
More ›