eliasmacpherson

Joined 16 years ago

Karma
1,089
Submissions
643
Member since
Jul 10
View on Hacker News

Recent submissions

Comment · 2 years ago
The ongoing weaponisation of psychological terms such as narcissist by the unqualified is another tiresome step along the euphemism treadmill. It may never stop as it is too simple a form of entertainment to resist.
Comment · 3 years ago
Thanks for the clarification.

So just to spell it out: Domain-driven design (nor Data-driven development per the article title, nor Data-driven design) aren't programming paradigms, they are software design approaches.

Whereas Data-driven programming, as linked from the above wikipedia is infact a paradigm and something else entirely. Alright.

They have 'Data-oriented' listed in the wikipedia paradigm article, but it links to 'Data-oriented design' which is clarified as a software design paradigm, as distinct from a programming paradigm.

Comment · 3 years ago
Comment · 3 years ago
Ah, well I guess I did take it as an example of something that was incompatible. It served well enough as a vehicle to drive the conversation forwards.

The iterator invalidation occurs when push_back(), insert() or erase() are called, presumably among others, so you'd also want to overload the iterator increment and decrement operators too (oh!, not to forget end(), or rend() if you are going the other way...). I'm not sure what operators and methods would be called on passing to an std::algorithm like std::find or std::sort. Most likely the only way to find out for certain would be to make everything inaccessible and replace piecemeal until the compiler was happy to run to completion.

I'd want to take a closer look where it's instantiated, but if all the uses are 'auto', well let's just say I'd be unhappy to say the least.

Comment · 3 years ago
I think the example is perfectly apt, and I would not know where to start wrapping a std::list/std::vector implementation to pick up on runtime iterator invalidation.
Comment · 3 years ago
> You design (or choose) the new type such that it actually is compatible with the old type.

Yes I agree, in that case sure, but when refactoring the case can arise that a new type must no longer compatible with the old type, then auto becomes a hindrance.

std::vector and std::list have different behaviour regarding the validity of iterators after deletion (EDIT: and insertion so it seems!), to pick an example.

Maybe I'm just paranoid?

Comment · 3 years ago
This refactoring business, I see it going two ways, there are probably more.

1. you refactor, you change the type declaration in one place, auto handles the boring work of replacing the characters throughout your project.

2. you refactor, you change the type definition in one place, auto will handle replacing all the instances in your project, hell, it might even compile afterwards.

I believe you are describing 1. I find that easy enough to do with 'Sed' or IDE refactoring tools.

2, is more subtle and the new behaviour could now be worthy of scrutiny throughout the project. I find it difficult then to 'Grep' or IDE search through the project for all instances reliably when auto is in use. It is much easier for me with spelled out types.

I would trade the benefit of auto in 1) for the safety of spelled out types in 2) every single time.

Comment · 3 years ago
Comment · 3 years ago
rust: std::simd efforts

midi: 2.0

web: local-first as a trend

Comment · 3 years ago
Comment · 3 years ago
To clarify:

The initial claim was, lxgr: "If you were initially fine with software emulation (i.e. Rosetta 2), as were many small and large software projects for macOS or Unix, you had no need whatsoever to get a DTK."

The subsequent claim was, xvector: "Rosetta 2 was straightforward and surprisingly fast, requiring zero tweaking or user interaction. Most people never even noticed."

Posters, myself included, are reacting against these claims, as they both put the cart before the horse, and the second gives only an end user perspective.

Devs had verified with a DTK that Rosetta2 ran their programs acceptably. Keep in mind patches had to be issued for programs which did not check for the presence of AVX, AVX2 or AVX512, else they would crash. This invalidates the first claim. It shows why the second claim is only the second half of the story.

So the logic follows a line rather than a circle.

Also nobody made the claim that: “And Apple made test hardware available for those people, But not enough for all apps to be tested”

Comment · 3 years ago
On Rosetta 2, from the horses mouth:

Rosetta translates all x86_64 instructions, but it doesn't support the execution of some newer instruction sets and processor features, such as AVX, AVX2, and AVX512 vector instructions.

I can imagine quite a number of users running into the above situation in multimedia related code.

Comment · 3 years ago
stealing is illegal, so I never lock my front door.
Comment · 3 years ago
Comment · 3 years ago
wait til you find out some people prefer their faculties dulled by a hangover than being fully present and in the moment for their dreary morning-midday routines.

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton