skysight-inc/HackerNews huggingface dataset:
I love seeing "strncpy" right after "strcpy."

If someone wants some fun, try this:

1. Slurp up all the FOSS projects that extend back to 90s or early 2000s.

2. Filter by starting at earliest snapshot and finding occurrences of strcpy and friends who don't have the "n" in the middle.

3. For those occurrences, see which ones were "fixed" by changing them to strncpy and friends in a later commit somewhere.

4. See if you can isolate that part of the code that has the strncpy/etc. and run gcc on it. Gcc-- for certain cases (string literals, I think)-- can report a warning if "n" has been set to a value that could cause an overflow.

I'm going to speculate that there was a period where C programmers were furiously committing a large number of errors to their codebases because the "n" stands for "safety."
The potential additional distance between Denmark and Norway is nothing compared to the overall distance of sailing halfway round the globe to Antartica.
Yeah there are footguns in every language. But this is not a boolean question about the presence of footguns, this is about how much one has to know to be able to handle a language safely.

I know C/C#/Python/Rust/Javascript.

After a decade of using C I am still not totally sure if I didn't dangle a pointer somwhere in precisely the wrong way to create havoc. And yeah, that means I have to get better, etc. But that is not the point. The point is, that even with a lot of experience in the language you can still easily shoot yourself into the foot and don't even notice it.

Meanwhile after a month of using Rust I felt confident that I didn't shoot myself in the foot, because I know what the compilers e.g. ownership guarantuees. While in C shooting myself into the foot happen quite often in Rust I would have to specifically find a way to shoot myself into the foot without the compiler yelling at me, and quite frankly I havent found such a way yet.

Javascript is odd, because the typesystem has quite a few footguns in it. This is why such things like Elm or Typescript exist: to avoid these footguns.

I don't want to take away from the accomplishments of C, and I still like the language, but to claim it is equally likely in all languages to shoot yourself into the foot is not true.
If we had put the money in renewables we almost certainly would have solved the problems by now.

My dad studied physics in the 60ies when fusion was just 20 years away.
First off, start looking at depression as a biochemical/hormonal imbalance in your body. Next, with this in mind, start looking for a cure. Will leaving the house more often help? Maybe, but not likely. What about antidepressants? Yes, that has a higher probability. For me, what got me off depression permanently after struggling for years was Testosterone Replacement Therapy.
> Why not check the git history?

Because that is effort every person who uses the file has to do over and over again, whereas maintaining the file is effort that has to be done once by one person.
Unsustainable was the wrong word. Correction -->. "can sustain a higher cash burn for longer before getting to revenue positive"
So nuclear is much much much much cheaper and until the storage costs come way down, we have no other choice (aside from natgas peakers). Correct?
What you propose to use instead of dams in place of flood protection?
It would be great if the BANNED() macro could suggest the correct function to use.
The HP "Munchkin" terminal would be nicer ;-)
Absolutely. Not by looking out of the windows though, but because of the magnitude of instruments pilots have in front of them to "see" the world around them.
It’s not hard to have strings like you do in other languages in C. It is hard when you treat char foo[] as if it was a string object like you have in JavaScript or Java or Python. C strings are just chunks of memory terminated by \0. They can still be mildly useful that way but if you actually want to do string operations you need to use a library designed for the problem (variable length, storing length with the object, Unicode support, etc.). Problem is that most people don’t start with such a library so they end up doing the hard work themselves in an ad hoc manner.

You can’t fuck up String(“Hello “) + String(“world”) but you can definitely fuck up strcat(buf, “Hello “); strcat(buf, “world”);.
It's hierarchical because of the nature of the data, not because of the model itself.
If he was such a pioneer of psychology and psychiatry, why is Freud pointedly ignored in Psychology and Psychiatry departments? And seriously, was the idea of subconscious motivations that innovative for his time?
Yes I saw that, but the parent comment said about it being a header ;)
> Normal people are seriously outgunned here.

This is quite right. PragmaticPulp's phrase "an act perpetrated by evil corporations on us helpless individuals" is a bit of rhetorical jujitsu, creating a strawman to set up a rallying cry "I believe people have agency!" You don't have to assume that individuals are "helpless", as if they are generally helpless and lacking agency, to agree that these corporations are exploiting them.

That said, people's agency is limited (bounded rationality). Awareness of how one is being manipulated is not evenly distributed among the population (asymmetric information). And even when there is awareness, people are unevenly affected by it and unevenly empowered to deal with it.
+1000

It’s just way easier to help women achieve success in a way that helps capitalists than it is to push for better working conditions for parents. But pushing for better working conditions isn’t impossible either, and the US is an extreme outlier in how hostile it is to working parents.
This idea is related to a study I saw some years ago. If you give a small sum to someone and tell them to spend it on themselves that person later will self report some mildly positive results. If you give a small sum to someone and tell them to spend it on someone else, they tend to self report higher positive results.

I can’t speak to the quality of the paper (not even sure how easy it would be to find), but I often think about repeating the experiment, or at least trying to provide some extra data points.

edit: I think this is the paper I was thinking of

https://www.researchgate.net/publication/5494996_Spending_Mo...
It amuses me that HN hates JS so much, that even a topic about problems with C turns into a JS-bashing thread.

Also, I just want to remind you that JS isn't just React. There are plenty of libraries written in C that introduce breaking changes over the course of 3 years. Nothing will stop people from finding ways to complain about JS though, I know. The hate-boner is very real.
It's not much and it's an expensive place to live, but Alaska pays each citizen a dividend each year. They do this from funds generated for the state from the oil and gas industry. It seems last year it was $992.

https://www.usnews.com/news/best-states/alaska/articles/2020...

I can imagine if the US federal government does the wealth tax Warren is pushing, closes some of the loopholes in corporate taxes, and then uses that for UBI it will help twofold.: The UBI itself and wages, being a legitimately deductible business expense, might just start rising more quickly.
I wish they would have put that on comments instead of on the commit messages. It's not the first time that I've seen this particular list of banned functions being shared online and every time it happens someone has to explain that the most interesting info is hidden in the commit messages.
If a highway robber stops you and demands "your money or your life" and you object, they can't justifiably say "well if you don't pay me, how do you propose things work?"

The responsibility isn't on the user to either consent to tracking or to come up with an alternative business model that allows people to monetize things. The responsibility for monetizing things falls on the people who want to do the monetizing. They have to figure out a business model that works and that users consent to.
- I already do exercise. Now, not especially, but it has never made a difference for me. A couple of years ago I was in a very good shape and I still had recurrent depression episodes.

- I don’t have any specific diagnosis regarding my mental health so I don’t take anything.

- Could you elaborate on the counseling thing? You mean like a psychologist?

The last point is very good. However, I’m not really “competitive”. I just want to live in peace. Thanks for your answer.
Engineers Have Proposed the First Model for a Physically Possible Warp Drive
The good news is, if you are right about nuclear being safe, then I will benefit from it.

If you are wrong, I will be too busy being dead to remember that I was right!
Our old mashupfm room is back in action, fun to see so many familiar faces I hadn't seen in years! https://turntable.fm/mashupfm
TSMC Rumored to Increase Capacity of Arizona Fab
What, so Google can just go ahead and delete them?
> "In any case, the desire to kill an animal to show off one's hunting prowess is rather on a different level to biological needs. Nobody _needs_ to kill an animal for sport in order to stay alive. Everybody needs to eat. That is the ocean of difference I refer to in my comment."

This is the disconnect I'm confused by.

Nobody _needs_ to eat meat to stay alive either. Plenty of people survive just fine without doing so (vegetarians and vegans).

It'd be different if we did need meat to live, but we don't.
Never thought I’d see my part of the world on here; used to drive through Weston under Lizard every day.

Some good place names in Shropshire, too, but Durham has my favourite with No Place and Pity Me.
Isn't it economically more efficient to have kids go to daycares (which benefit from economies of scale) and have both parents work and pay taxes?

Of course some people prefer to raise their kids themselves, but that seems more like an expensive lifestyle choice than a necessity.
Also a common term for a particular type of railway junction that resembles the river: https://en.wikipedia.org/wiki/Wye_(rail)
Does Ryzen compete on gigaflops-per-watt, though?

You know Intel's in hot water when AMD makes a better Intel chip than Intel does, though...
I feel like there's basically two business models in the world - you can be a baker, in which you try to create a product that customers will want on its merits, and work to make the best possible customer experience, or you can be a crack dealer. I think a lot of people think they're bakers, but you gotta realize, the moment you start sprinkling crack in the cookies, you're not selling cookies anymore.
OpenAPI (not Swagger; that's the old name for the spec and the current name for the toolset) has all of the above functionalities. One important component is, to get the best benefit, it should be used for specification and not (just) documentation; in other words, you define the contract first and then base the various implementations (both server and client side) on it.

Unfortunately there are not many tools that support that approach; I've tried to rectify that - for Python - with Pyotr [0].

[0] https://pyotr.readthedocs.io
You don't need fancy static analysis. You can find out whether the banned functions are called just by inspecting the compiled object file. Add it to the build step and done.
A lot less than I thought:

- HBO

- Digital Ocean

- Disney+

- YouTube Music
A handful of companies influencing the overton window of the entire nation in response to easily upset Twitter mobs is precisely what I consider to be part of cancel culture.
I have always had the intuition that my testosterone levels were not high.
It's not a universal rule that all for profit companies will "cut corners." Airplanes are vastly safer than other forms of transportation. When the public found out that Boeing cut corners with their design of the 737 max, their share price dramatically plummeted, signaling that this was the wrong decision.

Also, cutting corners isn't necessarily worse for nuclear than other energy sources. More people die from wind turbine accidents than nuclear power.
Rsync, the command line even, is familiar to vanishingly small slice of the Apple user base.

It’s amazing how out of touch developers on HN are from the average Apple user. Completely, utterly, impossibly out of touch with reality.

Try to imagine proposing a project like this to the internal teams at Apple and being asked “Who is this for!?”
There are poor people who don't work. There are workaholics who don't work, I know a few. Why? Because of mental illness, particularly depression. Poverty is a cause of mental illness.

Even if you manage to stay healthy, being poor is still stressful and exhausting. Exhaustion is easily confused for laziness.

People who are poor because they don't work generally don't work because they are poor.

> So no poor person is ever to blame for their situation?

As a matter of fact, they aren't. Even if they are poor just because they're lazy, you have to ask why. Is laziness genetic? Can't blame someone for their genes. Bad upbringing? Not their fault either. Not working on their attitude? Blaming them for being too lazy to do that would be a circular argument. So what do you want to blame them for?

That doesn't mean incentivizing people to work is wrong. But being poor is not a moral failure.
> Functions, equations, operators

All of those are part of Peano and ZFC axiomatic systems, which were thought to be enough to explain all of physics (albeit not easily). Matrices and imaginary numbers are not part of those formal systems.

Just ask yourself. If you are right, why didn't Schrodinger or the researches that are publishing this study just think of your idea of using matrices?
I just think that people need to out things into perspective. The tsunami that cause Fukushima was dar more damaging than the nuclear event, but people seem to only remember the nuclear event. I think in our mind we make these events far far more serious than they were. Not that they were not serious but every thing in life is a tradeoff and you need to look what you are trading and what you are getting.
How can you be sure is not the same with physical reality? Ie. That only your thought of it exists.

After all, the only thing that we can be certain of is our own (subjective) experience.
The Pattern Seekers: A New Theory of Human Invention
Grass is always greener for me but I often think if I could do it over I'd rather have children as early as possible instead of in my late 30s.

I think if I had known how young late 30s and 40s actually is it may have resonated. Like, I still do all of the hobbies and activities I did in my 20s and am arguably in the best shape of my life, pandemic bod not withstanding. I think I truly felt my youth was fleeting and I wanted to be able to "enjoy it".

The reality is I squandered it in some ways and I feel a bit of sadness that my children will have a dad in his 60s by the time they are out of the house. Should have given that youthful energy to them with something to spare as adults. In reality I probably won't have much left when they become adults.

Such is life!

EDIT: Someone down thread makes another point that applied to us. By the time we were "ready", we found we had "unexplained infertility". Science helped us out but it wasn't fun, it was stressful, and pushed our parenthood even later than planned.
Large parts of build speed issue with nuclear is regulation. If we could just get a permit to build done in a reasonable amount of time and then not stop progress again and again it would make a big difference.
There is still hope, but we sure do need a global mindset shift when it comes to nuclear (and many other topics for sure).

Global warming will make parts of the worlds inhabitable. Sea levels will rise, so much heat and humidity in some places that your body won't be able to regulate its internal temperature...
I teach at university as external lecturer. Teaching strings in C is the hardest thing I have to do every time. The university decided to explain C to first year student without previous experience. My feedback was to do a precourse in Python to let them relax a bit with programming as a concept and then teach C in a second course.
BTW, nuclear energy will be cheaper with massive power storage, because nuclear power can be accumulated at night then.
I ran into this on a government contract that wanted videos of certain things submitted in, per specification, "high definition digital video" okay 1080/60 it is.

Oh, no that's too big for them to email to their antiquated consultants, turns out they want 15MiB max video clips.

Well to do that I had to step down to 720/30. Which they then complained wasn't clear enough for their uses. Three rounds of RFI later I'm back as square one, they've defined HD as 1080/60 and they say they'll figure out how to distribute the clips. Just annoying as all get out when they could have started with clear language (numbers) to begin with.
Philosophic ignorance results among other things in existential crisis and gullibility. Is it observable and pragmatic enough? Another example is fallacies that were first identified in (philosophic) criticism of scholasticism and later expanded.
To avoid another repeated thread, just read this:

https://news.ycombinator.com/item?id=7709556

I just realized that you were posting on that thread as well.
> -regulating ISPs as a free market is, to be hyperbolic, a disaster. there is effectively a monopoly in most parts of the country.

> all in all, this reeks of regulatory capture to me. if we're gonna have a serious discussion about internet infrastructure, i think the starting point is how we classify ISPs and where in the city-state-federal hierarchy the responsibility lies. changing a 26 to a 100 is a cool bullet on a resume, but i dont think this is the low handing fruit here.

The distributed regulation is the biggest problem IMO. ISPs are generally granted explicit or effective monopolies by local governments. Local competition is difficult enough for a utility business, but city governments make it effectively impossible in many places. Then there's a few big players who are able to claim competition and get lenient regulation at the federal level.
You're right. They're encoding just regular JPEG for lossy compression. They're also using either ICER and LOCO for lossless compression. JP2 has been used for other Mars spacecraft (the HiRise orbiter, I believe), but the JPEG encoding was inherited from the Mars Insight lander (in 2018).
It is not only about eggs.

Childcare requires a lot of stamina: waking up at night, multitasking all the time. It is not something you want to start doing in your 40s until your late 50s.

You do not to have a huge age gap between you and your kid and be a parent that is tired all the time.
For baseline power the answer is yes. The only two forms of low carbon baseline energy we currently have are nuclear and hydro.
> steam explosion that would completely disassemble the pressure vessel and core and would place maximal stress on the containment building itself.

This venturing into the realm of hyperbole, at best. Nothing in your link mentions an explosion that would "completely disassemble the pressure vessel". Stress on the containment building isn't mentioned at all. These statements seem to be of your own invention.

Can you substantiate your claim that a pressure vessel failure stood to compromise the containment building?

> There is a huge different between "didn't explode today", and "can't explode ever"

Again, we set up our safety measures such that the danger is contained even if a meltdown occurs. Even the most scrutinized designs may fail. Humans are never perfect. You're right: no plant can guarantee that it can't fail. That's why safety measures are built to withstand failure.
I think in most cases it's probably not hate but a deep, deep love.
First thing I looked for. It looks like it was used here:

https://github.com/git/git/blob/master/object-file.c#L1293

And currently used here (at least):

https://github.com/git/git/blob/master/refs.c#L1235
I wish the PoC of these were written in Go or Rust so they could be built without weird hacks or dependencies.
> in principle you can always implement those optimizations by hand in C

Some things, like integral promotion rules, you can't get around. You may know that the promotion can be skipped in certain cases, but the compiler cannot know it.
Why are these functions deprecated in favor of others but not removed? I know in Javascript this can happen so as to not break older websites, but in a compiled language this shouldn't be a problem right?
1TB goes by shockingly fast with 4k video streaming (5-10 gigs per hour) and game updates that weight in at tens of gigs each.
I mean, Firefox ESR works pretty well.
I never could really understand the point of strncpy()... we always end up wrapping to deal with writing an unterminated string.

Was it intended for fixed length records?
True about income security. I am interested in a solution that looks something like the homemaking person operating as something that resembles a sole proprietorship focused on the care of children. Not a perfect solution but something in that vein.

Re “too easy”: I’m not talking about just wanting to raise a healthy family, the implication is that you actually do it. And that takes a lot of hard work.

The suggestion that two working parents provides optimal results is not true or sustainable in my experience and seems to be the undertone of the discussion: in order to have both parents working, someone probably sacrificed their most fertile years to build a resume. And this isn’t necessarily good for the future of our species.

Is a household with two stable incomes nice? Sure. At the expense of the woman’s fertility.. the sacrifice is questionable. Would also love to see our society support mothers of older children who need less immediate care entering the workforce not just young blood fresh out of high school and college.