KoalaUnknown@lemmy.world to Programmer Humor@programming.devEnglish · 3 months agoWhat's a readabilitylemmy.worldimagemessage-square59fedilinkarrow-up1161arrow-down116
arrow-up1145arrow-down1imageWhat's a readabilitylemmy.worldKoalaUnknown@lemmy.world to Programmer Humor@programming.devEnglish · 3 months agomessage-square59fedilink
minus-squareCrackedLinuxISO@lemmy.dbzer0.comlinkfedilinkEnglisharrow-up23·edit-23 months agoGary should learn about Lazy<T> and stop reinventing the wheel. I put blame on any of his senior coworkers who didn’t use this as a teaching opportunity during PR.
minus-squaredax@feddit.orglinkfedilinkarrow-up7·3 months agoOr just services.AddSingleton<X>. There’s plenty to criticize in C#, or any language, but this ain’t it. Most of the new language features just make the code shorter without loosing clarity. Really liking newer C# versions.
minus-squareGreenMartian@lemmy.dbzer0.comlinkfedilinkarrow-up6·3 months agoAlso, Lazy is thread safe. Gary’s code is not.
Gary should learn about Lazy<T> and stop reinventing the wheel.
I put blame on any of his senior coworkers who didn’t use this as a teaching opportunity during PR.
Or just
services.AddSingleton<X>. There’s plenty to criticize in C#, or any language, but this ain’t it. Most of the new language features just make the code shorter without loosing clarity. Really liking newer C# versions.Also, Lazy is thread safe. Gary’s code is not.