3 ms·
I feel like pretty much every language with generics has a LINQ, like functools/itertools in Python, lodash for javascript. It’s just a different expression of
by sherburt3 1y ago
I feel like pretty much every language with generics has a LINQ, like functools/itertools in Python, lodash for javascript. It’s just a different expression of the same ideas.
- jeswin 1y agoNope, very different. Depending on whether the expression is on an Enumerable or a Queryable, the compiler generates an anonymous function or an AST. That is, you can get "code as data" as in say Lisp; and allows expressions to be converted to say SQL based on the backend.
- pjmlp 1y agoYou can do exactly the same with Smalltalk metaclasses and reflection. However I do conceed most developers will only see them for the first time in .NET languages.