Re:Hard to work with
by 29athrowaway on Thursday March 31, 2022 @11:01AM
(#30867959)
And the generation Z version in case you are wondering is
function FuckYou(T) {
return class {
// something with T
};
}
Because you can return classes from a function.in C++? or JS or ...? :o
Re:Hard to work with
by 29athrowaway on Thursday March 31, 2022 @12:10PM
(#30868791)
My self reply was JS
Re:Hard to work with
by pgruenbacher on Thursday March 31, 2022 @11:56AM
(#30868627)
zig
Let's imagine there is a problem that requires to need to implement 100 classes to deal with 100 different types.
A 18th century person would say: I have 100 classes, 5 workers, I am going to give 20 classes for each worker to implement.
A person that actually knows what's going on would simply write template <typename T> class FuckYou, done.
In the wrong hands, software is misery.