Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I use VSCode with the C# LSP, but I prefer to immediately see where a name comes from by reading it, rather than hovering over it. That's why I prefer to avoid global.

Regarding imports, I guess I could do something like `using c = my.namespace.ClassWithMyStaticMethods`, but I suppose it's not idiomatic in C#.



> using c = my.namespace.ClassWithMyStaticMethods

Non idiomatic? IMO, this is completely fine. Idiomatic C# doesn't mean OO all the time.


Glad to hear. I'll consider this more then.


Better is `using static my.namespace.ClassWithMyStaticMethods` that gets you exactly the consuming syntax you want, even though the methods still need to be static on that class.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: