Hacker Newsnew | past | comments | ask | show | jobs | submit | vouwfietsman's commentslogin

Sure, but from the perspective of the code that has the move() its good to assume the value is moved at that call, which I guess was the intention of picking the name.

Usually yes, however because that's not for some resource types it can lead to less than ideal behaviour e.g. if your RAII resource is something which will get corrupted if there are two handles to it (some sort of odd hardware resource), you std::move() the object into a callee, assume it is moved and released, so you acquire a new resource, and turns out the callee did not move it and now you have two of them.

yes

std::move tells the devs and the compiler that you _intend_ the value to be moved

sadly that isn't reflected well in it's implementation as it will "silently" degrade even if it isn't a "move" (1)

A `std::move` which fails to compile if it can't be a move(1) it would not have this issues.

But it has other issues, mainly wrt. library design especially related to templates/generics, which probably(?) need a `std::move` which works like the current one. I think someone else in this comment section already argued that one issue with modern C++ is too much focusing on the complicated/template/const library design by experts case compared to the "day to day" usage by non experts.

(1): There is a bit of gray area in what in rust would be Copy types, for simplicity we can ignore them in this hypothetical argument about an alternative std::move design.


std::offer

∆ That's actually quite accurate. I like it!

std::abandon() ?!

Maybe a std::take to pair with it?

I think it would make sense to have these issues bubble up into the public consciousness of hackernews.

I've never used AI to code, I'm a software architect and currently assume I get little value out of an LLM. It would be useful for me if this debate had a vaguely engineering-smelling quality to it, because its currently just two groups shouting at eachother and handwaving criticism away.

If you actually deal with AI generated problems, I love it, please make a post about it so we have something concrete to point to.


PRs where somebody who clearly doesn't know the tech being used well enough, or enough about how the complex app they're working on really works, thus isn't able to determine a good design from a bad one for the feature they're working on, but has AI*-assisted themselves to something which "works", can become an absolute death spiral.

I wasted so much work time trying to steer one of these towards the light, which is very demotivating when design and "why did you do this?" questions are responded to with nothing but another flurry of commits. Even taking the time to fully understand the problem and suggest an alternative design which would fix most of the major issues did nothing (nothing useful must have emerged when that was fed into the coin slot...)

Since I started the review, I ended up becoming the "blocker" for this feature when people started asking why it wasn't landed yet (because I also have my own work to do), to the point where I just hit Approve because I knew it wouldn't work at all for the even more complex use cases I needed to implement in that area soon, so I could just fix/rewrite it then.

From my own experience, the sooner you accept code from an LLM the worse a time you're going to have. If wasn't a good solution or even was the wrong solution from the get-go, no amount of churning away at the code with an LLM will fix it. If you _don't know_ how to fix it yourself, you can't suddenly go from reporting your great progress in stand-ups to "I have nothing" - maybe backwards progress is one of those new paradigms we'll have to accept?


Here is a sample

We are talking about a "stupid" tool that parses a google sheet and makes calls to a third-party API

So there is one google sheet per team, with one column per person

One line per day

And each day, someone is in charge of the duty

The tool grabs the data from the sheet and configures pagerduty so that alerts go to the right person

Very basic, no cleverness needed, really straightforward actually

So we have 1 person that wrote the code, with AI. Then we have a second person that checked the code (with AI). Then the shit comes to my desk. To see this kind of cruft:

  def create_headers(api_token: str) -> dict:
    """Create headers for PagerDuty API requests.

    Args:
        api_token: PagerDuty API token.

    Returns:
        Headers dictionary.
    """
    return {
        "Accept": "application/vnd.pagerduty+json;version=2",
        "Authorization": f"Token token={api_token}",
        "Content-Type": "application/json",
    }
And then, we have 5 usage like this:

  def delete_override(
    base_url: str,
    schedule_id: str,
    override_id: str,
    api_token: str,
  ) -> None:
    """Delete an override from a schedule.

    Args:
        base_url: PagerDuty API base URL.
        schedule_id: ID of the schedule.
        override_id: ID of the override to delete.
        api_token: PagerDuty API token.
    """
    headers = create_headers(api_token)

    override_url = f"{base_url}/schedules/{schedule_id}/overrides/{override_id}"
    response = requests.delete(override_url, headers=headers, timeout=60)
    response.raise_for_status()


No HTTP keep-alive, no TCP reuse, the API key is passed down to every method, so is the API's endpoint. Timeout is defined in each method. The file is ~800 lines of python code, contains 19 methods and only deals with pagerduty (not google sheet). It tooks 2 fulltime days.

These people fail to produce anything meaningful, this is not really a surprise given their failure to do sane things with such a basic topic

Does AI brings good idea: obviously no, but we knew this. Does AI improves the quality of the result (regardless of the quality of the idea): apparently no Does AI improves productivity: again, given this example: no Are these people better, more skilled or else: no

Am I too demanding ? Am I asking too much ?


Try pasting that full code into Claude and prompting:

> No HTTP keep-alive, no TCP reuse, the API key is passed down to every method, so is the API's endpoint. Timeout is defined in each method. Fix all of those issues.


AI is a wonderful tool that will answer all of your questions, as long as you give it the right answer ? That's probably right.

Even in normal human-written code, it's not guaranteed to get the code completely correct in one-shot. That's why code review and QA still exists.

The issue here is more organizational with the engineers not getting the code up to standards before handing off, not the capabilities of the AI itself.


tell it the problem - it will introduce you to the keep-alives and reuses...

What if you don’t know the problem? That’s kind of the crux of the issue here. You still need an expert operator, and at that point it is just saving some typing, but not even necessarily saving time with all the back and forth.

I'm sorry your teammates have skill issues when it comes to using these tools.

> I'm an adult, and I can decide for myself.

No you can't, all of this stuff is designed to influence you without you knowing it, or you would not be influenced. This is like thinking advertisements have no effect on you.

People pay good money because they know it is effective, it is influencing you, you cannot decide for yourself.


So who gets to decide? Someone who is above influence? Who is that?

There has to be a lot more nuance. I clearly see that both Putin and the CCP do a lot of things predicated on the exact claim that their respective populations can not be left to decide for themselves. "People left free would make bad decisions, we the rulers are morally obligated to force them into a good path". I think this is the ostensible meaning of "freedom is slavery".


There has to be nuance yes. But the nuanced position starts with accepting the reality that a ton of people are indeed having their brain turned to goo. Just go outside of the bubble of somewhat tech literate highly educated young people and look at what 60+ year olds consume on Facebook.

There's AI generated content with tens of millions of views that is as fake as ancient aliens on the history channel but nobody seems to realize it. If you comment here there is a high chance you did not grow up among people with 8 years of basic education who haven't read a book in 20 years and believe quite literally everything they see. That is what a decent chunk of any population is like. The biggest blind spot of well-educated internet libertarians who taught themselves how to code at 15 is that they in all likelihood have no concept of how the average citizen navigates the world.

The problem with Putin isn't that he thinks a country needs intelligent and wise leaders, Plato would have told you the same thing. It's where he's steering it that's the issue and that the country's leadership is no more capable at the top than it is at the bottom.


Doubtful.

Love your progress, best of luck!

Thank you!

Indeed, it seems that the gap that is present politically between America and Europe is to some extent also playing out in the individual, even in the tech scene. This is a little alarming to me, as the idea of an alliance can break down on the political level and be repaired in the new cycle of elections, that's OK.

But if an individual American really thinks Europeans are as smug as described in this article, or if Europeans really think the way this article describes, there is a more concerning, deeper issue with the worldview of these historically well-aligned peoples.


Again this is a polarizing question.

There's nothing wrong with either perspective, rather its the case that the European perspective is different. That's not to say that Europeans are right, or that criticism flowing from Europe to America is justified, but it should at least be acknowledged that pitching two players in a competition that one of the players has less interest in competing on, is misguided.


This is not really fair, the story is never explicitly discounted as hyperbole in the article and follows a range of other more mellow criticisms of europe. Also, directly following this quote, is the question: "Could anyone imagine Chinese or Americans being so obedient?".

None of this points to the story being out of place, and since the author specializes in serious analysis of china's relation with america, and the author brings up europe, its fair to assume that they included this story as a relevant criticism of europe.

In that regard, its indeed not of the same quality as the analyses of china or american culture.


> poor is more about being rigid

Oh no please broaden your mindset. This is not a healthy way to look at wealth inequality in 2025. Being poor can happen for arbitrary reasons, and the impact can vary greatly across countries and continents. E.g if you get and recover from cancer in Europe you will be OK financially, while being ruined in America.

This is an extreme example, but the point is not to weigh individual examples but rather to recognize that you as an individual don't understand the circumstances that create or alleviate poverty, because entire government branches are dedicated to doing this and haven't figured it out.

Bottom line poverty is bad news for everyone, there's money to be made solving poverty. It's not a trivial problem to solve.


Do you feel that road safety dictates your life?

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: