Replies: 2 comments 1 reply
-
Still trying to wrap my head around the runtime (that @louthy kindly explained to me here) and hoping to have an AHA moment in the no so distant future. For now, the jump from |
Beta Was this translation helpful? Give feedback.
-
@bmazzarol Believe it or not, I actually have this in a Haskell project I'm working on at MMS I'd actually forgotten that C# could do qualified inherited names, so that it would be possible to have multiple members in a type with the same argument-lists. I'll keep it in mind once I've done by other refactorings 👍 |
Beta Was this translation helpful? Give feedback.
-
@louthy this is a combined question and idea.
Why are the
HasSomething<RT>
interfaces required?I get that it enforces the struct constraint, but that (IMHO) is not required as
Eff and Aff enforce it.
Is the ability to conjure it up using default that essential?
Could we not just create a dead simple interface,
And then create simple static functions to access it?
So the recipe is as follows,
It would be fantastic if there was a constraint that forced a generic to be an
interface, but apart from that it should work as per the old recipe.
C# will let the runtime struct stack the same interface as many times as required,
Even using it directly without a static wrapper is not the worst thing in the world (def not the worst code I have written),
Love to hear your thoughts.
Beta Was this translation helpful? Give feedback.
All reactions