Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
rumcajz
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
59 ms
·
511.
▲
by
rumcajz
11y ago
> ... and APIs are nothing but a big pile of details. And so is international law. But nobody really believes that international law is fundamentally a legal construct.
512.
▲
by
rumcajz
11y ago
Go join any standardisation committee to see for yourself.
513.
▲
by
rumcajz
11y ago
The goal is not to look like golang but to maintain locality: Implementation of one thing should be at one place, not at two different places.
514.
▲
by
rumcajz
11y ago
Now you made me curios. How would you go about doing it with functions? Keep in mind that the goal is to interleave conditions and the code in switch-like way.
515.
▲
by
rumcajz
11y ago
Uh, fixed. Your solution looks a lot like Duff's device :)
516.
▲
by
rumcajz
11y ago
Yes. That sound like the same thing.
517.
▲
by
rumcajz
11y ago
The "linked list on the stack" mechanism can be used even outside of metaprogramming context. Imagine you are traversing a binary tree and while doing so, you want to keep some data associated with every ancestor node of the one b
518.
▲
Advanced metaprogramming in C
(250bpm.com)
63 points
by
rumcajz
11y ago
|
17 comments
519.
▲
Let's stop kidding ourselves about APIs
(250bpm.com)
8 points
by
rumcajz
11y ago
|
0 comments
520.
▲
by
rumcajz
11y ago
It you go beyong ~1955 the documents get pretty scarce. Still it's a fascintating topic to research.
521.
▲
by
rumcajz
11y ago
Same thread.
522.
▲
by
rumcajz
11y ago
Using that definition, libmill is definitely coroutine-based. It does the scheduling itself.
523.
▲
by
rumcajz
11y ago
Yes, that's exactly what it is. But it also matches wikipedia's difinition of coroutine: "Coroutines are computer program components that generalize subroutines for nonpreemptive multitasking, by allowing multiple entry point
524.
▲
by
rumcajz
11y ago
Ability to prefix fields by size. Which in turn means you can't preallocate buffers because you don't know the sizes in advance.
525.
▲
by
rumcajz
11y ago
Timeout: finish in 10 seconds. Deadline: finish at 7:15:35PM. The advantage of deadlines is that you can define a fixed deadline and then re-use it for any number of calls, without having to subtract the time already spent in previous calls
526.
▲
Building a concurrent TCP server with libmill
(libmill.org)
69 points
by
rumcajz
11y ago
|
16 comments
527.
▲
Simple TCP server in C with libmill
(github.com)
3 points
by
rumcajz
11y ago
|
0 comments
528.
▲
The Second Use Case for Literate Programming
(250bpm.com)
2 points
by
rumcajz
11y ago
|
0 comments
529.
▲
by
rumcajz
11y ago
But if you extract each piece of code that doesn't fit the structured syntax into a separate function you'll end up with zillions of small functions witch have no clear semantics by themselves (only when considered within the cont
530.
▲
by
rumcajz
11y ago
do_stuff1() is a shorthand. It can be a block of code tens of lines long.
531.
▲
by
rumcajz
11y ago
It's a dirty little secret. Officially, of course, we are all using structured programming. But in private, everybody does break and continue!
532.
▲
by
rumcajz
11y ago
The thing is we have no clear idea what we mean when speaking about consciousness. Luckily, there are some people who honestly try to find out. Dan Dennett to name one. Also this talk about consciousness by Susan Blackmoore is both funny an
533.
▲
A case for unstructured programming
(250bpm.com)
13 points
by
rumcajz
11y ago
|
13 comments
534.
▲
by
rumcajz
11y ago
Don't frget about TCPMUX listening on port 1. (RFC 1078) That's a serious stuff that could see many applications even in today's world.
535.
▲
by
rumcajz
11y ago
You should have a look at a code writte by actual senior programmer, not a wannabe one. Senior people strive for maintainability.
536.
▲
by
rumcajz
11y ago
I would also add that unikernels make sense from the architectural point of view. Instead of running the monolithic behemoth of modern operating system, you can run something very basic, like a hypervisor and have everything else in optiona
537.
▲
by
rumcajz
11y ago
If your chair covers the area of Los Angeles, it'll sure have problems with changing landscape. If it's a regular-sized chair, less so.
538.
▲
by
rumcajz
11y ago
Aside of it being convenient for users, keeping the components small is good for the developer as it tends to tame the complexity to the acceptable level.
539.
▲
by
rumcajz
11y ago
The project was take over by Garrett D'Amore so it's up to him to decide on its future.
540.
▲
Where are Python macros?
(250bpm.com)
1 points
by
rumcajz
11y ago
|
0 comments
More ›