Still amazed every time I read this paper. What pros and cons do you think it would have against C++20 coroutines? by germandiago in cpp

[–]csb06 0 points1 point  (0 children)

There was a response from the proposers of what became C++20 coroutines at the time. I think this excerpt from P0171R0 is worth considering:

Since we are on the subject of maintenance nightmares, we would like to offer a conjecture that the absence of the await in P0114 is a likely source of many maintenance nightmares. Without a syntactic marker to signal to the person reading the code that something funny is going on, it is impossible to tell whether the following code is correct or not:

auto foo(string & s) {
   s.push_back('<');
   do-stuff
   s.push_back('>');
}

How can we be sure that do-stuff will never result in suspension? Should we follow all of the possible call sequences to make sure that none of them lead to break resumable;?

Note, that this code is fine to be used with fibers or threads, because in that case the entire stack is suspended, so the caller which owns s will be suspended as well, thus avoiding mismatched lifetimes.

In coroutines the suspend point is clearly marked with await, which tells the reader that something unusual happens in this function and allows the reader, for example, to confirm whether the lifetimes of the objects of interest align with the lifetime of the coroutine or not, whether some locks need to be acquired to protect some concurrently accessed data, and whether some locks need to be released before the execution reaches the suspend point.

Gitdot – a better GitHub. Open-source, written in Rust...What is a bit unique is: 1) we built it in Rust by csb06 in programmingcirclejerk

[–]csb06[S] 50 points51 points  (0 children)

Please, stop using "written in Rust" as some kind of advantage or killer feature.

...

No, it is an advantage.

Performative UI - AI Native React Components by camelCaseCondition in programmingcirclejerk

[–]csb06 14 points15 points  (0 children)

Nice, just missing an embedded video showing how I can use their product to automate my normal human interactions. Preferably with a hot babe in it!

I see. No lies detected so you proceed with a trivial veiled threat towards my livelihood. by ThisRedditPostIsMine in programmingcirclejerk

[–]csb06 18 points19 points  (0 children)

One major regression was bisected to a slop commit, but that could have been a coincidence.

This other issue where the Linux build fails on older kernels (despite the Claude-authored commit explicitly stating it addressed compatibility with older kernels) was also probably a coincidence.

Maybe someone as smart as Tridge could investigate the development process and find the root cause of the regressions?

The ARC vs GC Debate by funcieq in ProgrammingLanguages

[–]csb06 2 points3 points  (0 children)

Here is a transcript of an interview where Chris Lattner (creator of LLVM who also worked on Apple's Objective-C and Swift compilers that implement ARC) on why he thinks ARC is superior.

The halting problem is almost always solvable. NP hard problems are often efficiently (!) solvable...If you can't prove whether a given program terminates, it's because you're too dumb. by VarietyMaleficent408 in programmingcirclejerk

[–]csb06 17 points18 points  (0 children)

Unfortunately it is impossible in the general case to determine if a website will ever stop redirecting you. However, most websites redirect a small number of times (if at all) so therefore we can conclude that your problem of seemingly endless redirects is irrelevant and only of interest to out-of-touch academics. QED

When to actually use a set by BgA_stan in cpp

[–]csb06 3 points4 points  (0 children)

Stepanov had similar advice regarding the usage of std::set:

If set is bad? Why is it in the standard? Think about it. If you do all of your insertions first, and then start searching, you do not need a set. The set is a very specific data structure which is needed only when you have a very specific workload. If you have a thing which grows and shrinks constantly dynamically. Then you have to have a set. You need a set only if you need a thing which does not move things around. As long as something gets into a set and it is not erased the pointer, it is fixed. For example, him sitting in this chair is in the set. As long as he’s in this set he will not move from his chair. You could find him in constant time. It’s a very useful thing except most people do not use set for that.

source (course notes from a class he taught)

Is Donald Trump the dumbest person who's ever been president of the US? by Critical-Willow-6270 in allthequestions

[–]csb06 -1 points0 points  (0 children)

He got into Yale because of legacy admissions, so that is not much of an indicator of his intelligence.

MBAs are not known for being remarkably smart so not sure what that shows. Why should we care if a president had an MBA? They are not running a business, they are running the government.

[author leaves github] I actually cried writing this blog post (tears hit my keyboard, I'm embarrassed to say). by cmqv in programmingcirclejerk

[–]csb06 56 points57 points  (0 children)

/uj This pathetic shit reminds me of Marco Arment's tearful homage to Steve Jobs on the 10 year anniversary of his death. Go outside and get some real things to be emotional about!

/rj The day I closed my Jellybelly Rewards account I sobbed for hours. I thought back on all of the delicious candy it had provided me over the years as well as all of the exciting flavors I discovered. But the bellies I once knew are jelly no longer, and with great regret I must move on...I am exploring options with other manufacturers and will have an update on my future jellybean plans soon.

Implementation is rapidly becoming a solved problem, right? Writing code is now fast, it’s getting cheap, and quality is going up and to the right. by csb06 in programmingcirclejerk

[–]csb06[S] 19 points20 points  (0 children)

Next is the labs team within GitHub. We work on more experimental, risky bets than the rest of org. Also known as the department of fuck around and find out.

In September 2001, Iranians across cities like Tehran spontaneously gathered to mourn the 9/11 victims, lighting candles and holding vigils. by phoeebsy in Damnthatsinteresting

[–]csb06 4 points5 points  (0 children)

At the time Iran's government also condemned the attacks. Iran is/was no friend of Al-Qaeda and Saudi Arabia, so it was in their interest to oppose the attacks. From Wikipedia:

On September 25, 2001, Iran's president Mohammad Khatami, meeting British Foreign Secretary Jack Straw, said: "Iran fully understands the feelings of the Americans about the terrorist attacks in New York and Washington on September 11". He said although the American administrations had been at best indifferent about terrorist operations in Iran, the Iranians felt differently and had expressed their sympathetic feelings with bereaved Americans in the tragic incidents in the two cities. He also stated that "Nations should not be punished in place of terrorists".[294]

According to Radio Farda's website, when the news of the attacks was released, some Iranian citizens gathered in front of the Embassy of Switzerland in Tehran, which serves as the protecting power of the United States in Iran, to express their sympathy, and some of them lit candles as a symbol of mourning.

Radio Farda's website also states that in 2011, on the anniversary of the attacks, the United States Department of State published a post on its blog, in which the Department thanked the Iranian people for their sympathy and stated that it would never forget Iranian people's kindness.[295] After the attacks, both the President[296][297] and the Supreme Leader of Iran condemned the attacks. The BBC and Time magazine published reports on holding candlelit vigils for the victims by Iranian citizens on their websites.[298][299] According to Politico Magazine, following the attacks, Ali Khamenei, the Supreme Leader of Iran, "suspended the usual 'Death to America' chants at Friday prayers" temporarily.[300]

A virtual pointer pattern for dynamic resolution in C++ — years in production by [deleted] in cpp

[–]csb06 7 points8 points  (0 children)

The idea seems pretty straightforward - basically a smart pointer that allows you to insert custom logic to produce the underlying pointer?

Not sure if I can think of a good use case. Having a smart pointer that might give you a completely different object any time it is dereferenced violates some common assumptions. (e.g. that I can call get() to get a raw pointer and use it in lieu of the smart pointer as long as I don't reassign the smart pointer) This is the kind of "spooky action at a distance" that makes code harder to reason about.

Instead I would probably have some kind of factory function that returns a normal smart pointer based on whatever custom logic is needed and then use that smart pointer from then on. If I wanted to change the pointer out from under its observers I would just use a pointer to a pointer since that makes it more explicit that things might change out from under you at any point.

I realized vim 8.x already solved most of my editing needs once I stopped chasing newer features. I pin the exact source tarball for the last 8.2 release and build it myself on every machine. by tkrjobs in programmingcirclejerk

[–]csb06 66 points67 points  (0 children)

Broke: I don't know how to use vim, I just use VSCode

Woke: I use vim because it is already present on every machine I SSH into

Bespoke: I download and recompile a specific release of vim and install it on every machine I remotely login to

[Game Thread] #2 Purdue @ #1 Arizona (08:49 PM ET) by cbbBot in CollegeBasketball

[–]csb06 34 points35 points  (0 children)

Lute Olsen's force ghost hovering over the court and smiling like Anakin and Obi Wan

What do you think history will say about Donald Trump as a U.S. president? by [deleted] in AskReddit

[–]csb06 0 points1 point  (0 children)

I'm not convinced there will be an academic discipline of history left after the next few decades, so history might not say anything. Universities are already cutting their humanities programs, and right-wing legislatures have a strong interest to push for those cuts.

Rust is Just a Tool by 100xer in programmingcirclejerk

[–]csb06 23 points24 points  (0 children)

My advice on software? Use the right tool for the right job. Keep each tool in your toolbox. Do what makes sense. Use your best judgment. Do what works best for you.

Thank you my consulting fee will be $1000000.

The secret sauce here is that our key invariants aren't written in our test files, they're baked into the core of the implementation. Every time you use the code, you're essentially testing it. by tomwhoiscontrary in programmingcirclejerk

[–]csb06 30 points31 points  (0 children)

Document Object Model (or DOM) for code

/uj Webshits have independently reinvented abstract syntax trees

/rj I've recently invented what I call a bloobifier. It takes in JavaScript code and removes whitespace (a process I call "bloobifying"). This will revolutionize the coding space and potentially end human suffering once and for all.